mirror of
https://github.com/nlohmann/json.git
synced 2026-02-28 22:36:25 +00:00
Added class hierarchy for user-defined exceptions (#244). Integrated parse exceptions 101-103. Parse exceptions include the byte count of the last read character to locate the position of the error (#301).
This commit is contained in:
@@ -79,7 +79,7 @@ TEST_CASE("compliance tests from json.org")
|
||||
CAPTURE(filename);
|
||||
json j;
|
||||
std::ifstream f(filename);
|
||||
CHECK_THROWS_AS(j << f, std::invalid_argument);
|
||||
CHECK_THROWS_AS(j << f, json::parse_error);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -757,7 +757,7 @@ TEST_CASE("nst's JSONTestSuite")
|
||||
CAPTURE(filename);
|
||||
std::ifstream f(filename);
|
||||
json j;
|
||||
CHECK_THROWS_AS(j << f, std::invalid_argument);
|
||||
CHECK_THROWS_AS(j << f, json::parse_error);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -810,7 +810,7 @@ TEST_CASE("nst's JSONTestSuite")
|
||||
CAPTURE(filename);
|
||||
std::ifstream f(filename);
|
||||
json j;
|
||||
CHECK_THROWS_AS(j << f, std::invalid_argument);
|
||||
CHECK_THROWS_AS(j << f, json::parse_error);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user