MCPcopy Create free account
hub / github.com/FastLED/FastLED / test_map_size_clear

Function test_map_size_clear

tests/misc/containers.cpp:562–575  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

560// Size and clear for map containers
561template<typename Map>
562void test_map_size_clear() {
563 Map m;
564 FL_CHECK(m.empty());
565 FL_CHECK(m.size() == 0);
566
567 m.insert(fl::make_pair(1, 100));
568 m.insert(fl::make_pair(2, 200));
569 FL_CHECK(!m.empty());
570 FL_CHECK(m.size() == 2);
571
572 m.clear();
573 FL_CHECK(m.empty());
574 FL_CHECK(m.size() == 0);
575}
576
577// Count method for map containers
578template<typename Map>

Callers

nothing calls this directly

Calls 5

make_pairFunction · 0.85
emptyMethod · 0.45
sizeMethod · 0.45
insertMethod · 0.45
clearMethod · 0.45

Tested by

no test coverage detected