| 33 | } |
| 34 | |
| 35 | void Checker(std::vector<RoutingOptions::Road> const & include) |
| 36 | { |
| 37 | RoutingOptions options = CreateOptions(include); |
| 38 | |
| 39 | for (auto type : include) |
| 40 | TEST(options.Has(type), ()); |
| 41 | |
| 42 | auto max = static_cast<RoadType>(RoutingOptions::Road::Max); |
| 43 | for (uint8_t i = 1; i < max; i <<= 1) |
| 44 | { |
| 45 | bool hasInclude = false; |
| 46 | auto type = static_cast<RoutingOptions::Road>(i); |
| 47 | for (auto has : include) |
| 48 | hasInclude |= (type == has); |
| 49 | |
| 50 | if (!hasInclude) |
| 51 | TEST(!options.Has(static_cast<RoutingOptions::Road>(i)), ()); |
| 52 | } |
| 53 | } |
| 54 | |
| 55 | UNIT_TEST(RoutingOptionTest) |
| 56 | { |
no test coverage detected