We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents b97f005 + 2bf7601 commit dbe2a96Copy full SHA for dbe2a96
std/csv.d
@@ -1118,14 +1118,12 @@ public:
1118
// @system due to the catch for Throwable
1119
@system pure unittest
1120
{
1121
+ import std.exception : assertNotThrown;
1122
enum failData =
1123
"name, surname, age
1124
Joe, Joker, 99\r";
- bool pass = true;
1125
auto r = csvReader(failData);
1126
- try foreach (entry; r){}
1127
- catch pass = false;
1128
- assert(pass);
+ assertNotThrown((){foreach (entry; r){}}());
1129
}
1130
1131
/*
0 commit comments