Commit d31492e2cd130885dccc098398a6f980bb84b186

Authored by Jarryd Beck
1 parent 5da5d671

Catch exception using reference

Showing 1 changed file with 1 additions and 1 deletions
test/options.cpp
@@ -229,7 +229,7 @@ TEST_CASE("Positional not valid", "[positional]") { @@ -229,7 +229,7 @@ TEST_CASE("Positional not valid", "[positional]") {
229 char** argv = av.argv(); 229 char** argv = av.argv();
230 auto argc = av.argc(); 230 auto argc = av.argc();
231 231
232 - CHECK_THROWS_AS(options.parse(argc, argv), cxxopts::option_not_exists_exception); 232 + CHECK_THROWS_AS(options.parse(argc, argv), cxxopts::option_not_exists_exception&);
233 } 233 }
234 234
235 TEST_CASE("Empty with implicit value", "[implicit]") 235 TEST_CASE("Empty with implicit value", "[implicit]")