Incorrect error message when unable to snap all input coordinates (#5846)
In cases where we are unable to find a phantom node for an input coordinate, we return an error indicating which coordinate failed. This would always refer to the coordinate with index equal to the number of valid phantom nodes found. We fix this by instead returning the first index for which a phantom node could not be found.
This commit is contained in:
@@ -242,6 +242,8 @@ BOOST_AUTO_TEST_CASE(test_table_no_segment_for_some_coordinates)
|
||||
BOOST_CHECK(rc == Status::Error);
|
||||
const auto code = json_result.values.at("code").get<json::String>().value;
|
||||
BOOST_CHECK_EQUAL(code, "NoSegment");
|
||||
const auto message = json_result.values.at("message").get<json::String>().value;
|
||||
BOOST_CHECK_EQUAL(message, "Could not find a matching segment for coordinate 0");
|
||||
}
|
||||
|
||||
BOOST_AUTO_TEST_CASE(test_table_serialiaze_fb)
|
||||
|
||||
Reference in New Issue
Block a user