| 120 | BOOST_AUTO_TEST_SUITE(test_custom_allocator) |
| 121 | |
| 122 | BOOST_AUTO_TEST_CASE(test_custom_allocator_1) { |
| 123 | // nb_global_new = 0; |
| 124 | nb_custom_allocs = 0; |
| 125 | |
| 126 | tsl::ordered_map<int, int, std::hash<int>, std::equal_to<int>, |
| 127 | custom_allocator<std::pair<int, int>>> |
| 128 | map; |
| 129 | |
| 130 | const int nb_elements = 1000; |
| 131 | for (int i = 0; i < nb_elements; i++) { |
| 132 | map.insert({i, i * 2}); |
| 133 | } |
| 134 | |
| 135 | BOOST_CHECK_NE(nb_custom_allocs, 0u); |
| 136 | // BOOST_CHECK_EQUAL(nb_global_new, 0); |
| 137 | } |
| 138 | |
| 139 | BOOST_AUTO_TEST_SUITE_END() |