From f793d21e966b9d6c436cca6cd6d8af1e50d99e77 Mon Sep 17 00:00:00 2001 From: jatin Date: Mon, 17 Jun 2024 13:01:27 -0700 Subject: [PATCH 01/10] Trying to fix Windows CI --- .github/workflows/run-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index f3b09688..e006a23c 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -38,7 +38,7 @@ jobs: build_type: "Release" - name: "Test" os: windows-2022 - build_type: "Release" + build_type: "Debug" - name: "Coverage" os: ubuntu-22.04 cmake_args: "-DCODE_COVERAGE=ON -DCMAKE_BUILD_TYPE=Debug" From 1c3bf97192951df9d6598ac833cd280f7444a728 Mon Sep 17 00:00:00 2001 From: jatin Date: Mon, 17 Jun 2024 18:26:17 -0700 Subject: [PATCH 02/10] Triage --- .../AbstractTreeTest.cpp | 106 ++++++++--------- .../EnumMapTest.cpp | 112 +++++++++--------- .../STLArenaAllocatorTest.cpp | 2 +- 3 files changed, 110 insertions(+), 110 deletions(-) diff --git a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp index d52487f0..1d295f21 100644 --- a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp @@ -105,57 +105,57 @@ TEST_CASE ("Abstract Tree Test", "[common][data-structures]") REQUIRE (b_node->tag == "b"); } - SECTION ("Remove Multiple") - { - tree.removeElements ([] (const std::string& el) - { return el.find ('t') != std::string::npos; }); - REQUIRE (tree.size() == 2); - - REQUIRE (tree.getRootNode().first_child == tree.getRootNode().last_child); - REQUIRE (tree.getRootNode().first_child->tag == "a"); - } - - SECTION ("Remove All") - { - tree.removeElements ([] (const std::string& el) - { return ! el.empty(); }); - REQUIRE (tree.size() == 0); - - tree.insertElement ("mussels"); - REQUIRE (tree.size() == 1); - REQUIRE (tree.getRootNode().first_child->tag == "m"); - REQUIRE (tree.getRootNode().first_child->first_child->leaf == "mussels"); - - auto* found = tree.findElement ("mussels"); - REQUIRE (found != nullptr); - } - - SECTION ("Find Success") - { - auto* found = std::as_const (tree).findElement ("apples"); - jassert (found != nullptr); - } - - SECTION ("Find Fail") - { - [[maybe_unused]] auto* found = std::as_const (tree).findElement ("bologna"); - jassert (found == nullptr); - } - - SECTION ("To Uppercase") - { - tree.doForAllElements ( - [] (std::string& str) - { - for (auto& c : str) - c = static_cast (std::toupper (static_cast (c))); - }); - - std::as_const (tree).doForAllElements ( - [] (const std::string& str) - { - for (auto& c : str) - REQUIRE (((c >= 'A') && (c <= 'Z'))); - }); - } + // SECTION ("Remove Multiple") + // { + // tree.removeElements ([] (const std::string& el) + // { return el.find ('t') != std::string::npos; }); + // REQUIRE (tree.size() == 2); + // + // REQUIRE (tree.getRootNode().first_child == tree.getRootNode().last_child); + // REQUIRE (tree.getRootNode().first_child->tag == "a"); + // } + // + // SECTION ("Remove All") + // { + // tree.removeElements ([] (const std::string& el) + // { return ! el.empty(); }); + // REQUIRE (tree.size() == 0); + // + // tree.insertElement ("mussels"); + // REQUIRE (tree.size() == 1); + // REQUIRE (tree.getRootNode().first_child->tag == "m"); + // REQUIRE (tree.getRootNode().first_child->first_child->leaf == "mussels"); + // + // auto* found = tree.findElement ("mussels"); + // REQUIRE (found != nullptr); + // } + // + // SECTION ("Find Success") + // { + // auto* found = std::as_const (tree).findElement ("apples"); + // jassert (found != nullptr); + // } + // + // SECTION ("Find Fail") + // { + // [[maybe_unused]] auto* found = std::as_const (tree).findElement ("bologna"); + // jassert (found == nullptr); + // } + // + // SECTION ("To Uppercase") + // { + // tree.doForAllElements ( + // [] (std::string& str) + // { + // for (auto& c : str) + // c = static_cast (std::toupper (static_cast (c))); + // }); + // + // std::as_const (tree).doForAllElements ( + // [] (const std::string& str) + // { + // for (auto& c : str) + // REQUIRE (((c >= 'A') && (c <= 'Z'))); + // }); + // } } diff --git a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp index cb0051c1..34a6562a 100644 --- a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp @@ -40,60 +40,60 @@ TEST_CASE ("Enum Map Test", "[common][data-structures]") STATIC_REQUIRE (map.at (Food::Banana) == std::nullopt); } - SECTION ("Insertion/Erasure") - { - chowdsp::EnumMap map {}; - map.insert_or_assign (Food::Apple, 22); - map.emplace (Food::Green_Beans, 23); - map.emplace (Food::Egg); - - REQUIRE (! map.empty()); - REQUIRE (map.size() == 3); - REQUIRE (*map.at (Food::Apple) == 22); - REQUIRE (map[Food::Green_Beans] == 23); - REQUIRE (map[Food::Egg] == 0); - REQUIRE (*std::as_const (map).at (Food::Apple) == 22); - REQUIRE (std::as_const (map)[Food::Green_Beans] == 23); - REQUIRE (map.at (Food::Banana) == std::nullopt); - - map.erase (Food::Green_Beans); - REQUIRE (map.at (Food::Green_Beans) == std::nullopt); - - REQUIRE (map.contains (Food::Apple)); - REQUIRE (! map.contains (Food::Green_Beans)); - - map.clear(); - REQUIRE (map.empty()); - } - - SECTION ("Iteration") - { - chowdsp::EnumMap map { - { Food::Apple, 22 }, - { Food::Green_Beans, 23 }, - }; - - size_t iter = 0; - for (auto [key, val] : std::as_const (map)) - { - jassert (iter < 2); - if (iter == 0) - { - REQUIRE (key == Food::Apple); - REQUIRE (val == 22); - } - else - { - REQUIRE (key == Food::Green_Beans); - REQUIRE (val == 23); - } - ++iter; - } - - iter = 0; - for (auto [key, val] : map) - val = (int) iter++; - REQUIRE (map[Food::Apple] == 0); - REQUIRE (map[Food::Green_Beans] == 1); - } + // SECTION ("Insertion/Erasure") + // { + // chowdsp::EnumMap map {}; + // map.insert_or_assign (Food::Apple, 22); + // map.emplace (Food::Green_Beans, 23); + // map.emplace (Food::Egg); + // + // REQUIRE (! map.empty()); + // REQUIRE (map.size() == 3); + // REQUIRE (*map.at (Food::Apple) == 22); + // REQUIRE (map[Food::Green_Beans] == 23); + // REQUIRE (map[Food::Egg] == 0); + // REQUIRE (*std::as_const (map).at (Food::Apple) == 22); + // REQUIRE (std::as_const (map)[Food::Green_Beans] == 23); + // REQUIRE (map.at (Food::Banana) == std::nullopt); + // + // map.erase (Food::Green_Beans); + // REQUIRE (map.at (Food::Green_Beans) == std::nullopt); + // + // REQUIRE (map.contains (Food::Apple)); + // REQUIRE (! map.contains (Food::Green_Beans)); + // + // map.clear(); + // REQUIRE (map.empty()); + // } + // + // SECTION ("Iteration") + // { + // chowdsp::EnumMap map { + // { Food::Apple, 22 }, + // { Food::Green_Beans, 23 }, + // }; + // + // size_t iter = 0; + // for (const auto& [key, val] : std::as_const (map)) + // { + // jassert (iter < 2); + // if (iter == 0) + // { + // REQUIRE (key == Food::Apple); + // REQUIRE (val == 22); + // } + // else + // { + // REQUIRE (key == Food::Green_Beans); + // REQUIRE (val == 23); + // } + // ++iter; + // } + // + // iter = 0; + // for (auto [key, val] : map) + // val = (int) iter++; + // REQUIRE (map[Food::Apple] == 0); + // REQUIRE (map[Food::Green_Beans] == 1); + // } } diff --git a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp index bfeeffab..017afca9 100644 --- a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp @@ -4,7 +4,7 @@ TEST_CASE ("STL Arena Allocator Test", "[common][data-structures]") { using Arena = chowdsp::ArenaAllocator<>; - Arena arena { 128 }; + Arena arena { 512 }; using Alloc = chowdsp::STLArenaAllocator; Alloc alloc { arena }; From 6f36e5fd01fb6680d973b64120029e653725e724 Mon Sep 17 00:00:00 2001 From: jatin Date: Mon, 17 Jun 2024 18:35:52 -0700 Subject: [PATCH 03/10] More triage --- .../AbstractTreeTest.cpp | 70 +++++++++---------- .../EnumMapTest.cpp | 52 +++++++------- .../STLArenaAllocatorTest.cpp | 18 ++--- 3 files changed, 70 insertions(+), 70 deletions(-) diff --git a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp index 1d295f21..2854b970 100644 --- a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp @@ -69,41 +69,41 @@ TEST_CASE ("Abstract Tree Test", "[common][data-structures]") } } - SECTION ("Remove One") - { - tree.removeElement ("beets"); - REQUIRE (tree.size() == 3); - - const auto* d_node = tree.getRootNode().first_child->next_sibling; - REQUIRE (d_node->tag == "d"); - } - - SECTION ("Remove From Start of Sub-Tree") - { - tree.removeElement ("alfalfa"); - REQUIRE (tree.size() == 3); - - const auto* a_node = tree.getRootNode().first_child; - REQUIRE (a_node->first_child->leaf == "apples"); - } - - SECTION ("Remove From End of Sub-Tree") - { - tree.removeElement ("apples"); - REQUIRE (tree.size() == 3); - - const auto* a_node = tree.getRootNode().first_child; - REQUIRE (a_node->last_child->leaf == "alfalfa"); - } - - SECTION ("Remove Last Node in Sub-Tree") - { - tree.removeElement ("donuts"); - REQUIRE (tree.size() == 3); - - const auto* b_node = tree.getRootNode().last_child; - REQUIRE (b_node->tag == "b"); - } + // SECTION ("Remove One") + // { + // tree.removeElement ("beets"); + // REQUIRE (tree.size() == 3); + // + // const auto* d_node = tree.getRootNode().first_child->next_sibling; + // REQUIRE (d_node->tag == "d"); + // } + // + // SECTION ("Remove From Start of Sub-Tree") + // { + // tree.removeElement ("alfalfa"); + // REQUIRE (tree.size() == 3); + // + // const auto* a_node = tree.getRootNode().first_child; + // REQUIRE (a_node->first_child->leaf == "apples"); + // } + // + // SECTION ("Remove From End of Sub-Tree") + // { + // tree.removeElement ("apples"); + // REQUIRE (tree.size() == 3); + // + // const auto* a_node = tree.getRootNode().first_child; + // REQUIRE (a_node->last_child->leaf == "alfalfa"); + // } + // + // SECTION ("Remove Last Node in Sub-Tree") + // { + // tree.removeElement ("donuts"); + // REQUIRE (tree.size() == 3); + // + // const auto* b_node = tree.getRootNode().last_child; + // REQUIRE (b_node->tag == "b"); + // } // SECTION ("Remove Multiple") // { diff --git a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp index 34a6562a..e25b4c68 100644 --- a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp @@ -40,32 +40,32 @@ TEST_CASE ("Enum Map Test", "[common][data-structures]") STATIC_REQUIRE (map.at (Food::Banana) == std::nullopt); } - // SECTION ("Insertion/Erasure") - // { - // chowdsp::EnumMap map {}; - // map.insert_or_assign (Food::Apple, 22); - // map.emplace (Food::Green_Beans, 23); - // map.emplace (Food::Egg); - // - // REQUIRE (! map.empty()); - // REQUIRE (map.size() == 3); - // REQUIRE (*map.at (Food::Apple) == 22); - // REQUIRE (map[Food::Green_Beans] == 23); - // REQUIRE (map[Food::Egg] == 0); - // REQUIRE (*std::as_const (map).at (Food::Apple) == 22); - // REQUIRE (std::as_const (map)[Food::Green_Beans] == 23); - // REQUIRE (map.at (Food::Banana) == std::nullopt); - // - // map.erase (Food::Green_Beans); - // REQUIRE (map.at (Food::Green_Beans) == std::nullopt); - // - // REQUIRE (map.contains (Food::Apple)); - // REQUIRE (! map.contains (Food::Green_Beans)); - // - // map.clear(); - // REQUIRE (map.empty()); - // } - // + SECTION ("Insertion/Erasure") + { + chowdsp::EnumMap map {}; + map.insert_or_assign (Food::Apple, 22); + map.emplace (Food::Green_Beans, 23); + map.emplace (Food::Egg); + + REQUIRE (! map.empty()); + REQUIRE (map.size() == 3); + REQUIRE (*map.at (Food::Apple) == 22); + REQUIRE (map[Food::Green_Beans] == 23); + REQUIRE (map[Food::Egg] == 0); + REQUIRE (*std::as_const (map).at (Food::Apple) == 22); + REQUIRE (std::as_const (map)[Food::Green_Beans] == 23); + REQUIRE (map.at (Food::Banana) == std::nullopt); + + map.erase (Food::Green_Beans); + REQUIRE (map.at (Food::Green_Beans) == std::nullopt); + + REQUIRE (map.contains (Food::Apple)); + REQUIRE (! map.contains (Food::Green_Beans)); + + map.clear(); + REQUIRE (map.empty()); + } + // SECTION ("Iteration") // { // chowdsp::EnumMap map { diff --git a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp index 017afca9..bda81e56 100644 --- a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp @@ -15,13 +15,13 @@ TEST_CASE ("STL Arena Allocator Test", "[common][data-structures]") REQUIRE (vec.front() == 1); REQUIRE (vec.back() == 4); - vec.push_back (5); - REQUIRE (vec.size() == 5); - REQUIRE (vec.back() == 5); - - vec.erase (vec.begin()); - REQUIRE (vec.size() == 4); - vec.insert (vec.begin(), 0); - REQUIRE (vec.size() == 5); - REQUIRE (vec.front() == 0); + // vec.push_back (5); + // REQUIRE (vec.size() == 5); + // REQUIRE (vec.back() == 5); + // + // vec.erase (vec.begin()); + // REQUIRE (vec.size() == 4); + // vec.insert (vec.begin(), 0); + // REQUIRE (vec.size() == 5); + // REQUIRE (vec.front() == 0); } From 3c3e2cf14f8935ee75862cd5fee5534c0a2cc9e5 Mon Sep 17 00:00:00 2001 From: jatin Date: Mon, 17 Jun 2024 18:43:13 -0700 Subject: [PATCH 04/10] Even more triage --- .../AbstractTreeTest.cpp | 62 +++++++++---------- .../EnumMapTest.cpp | 60 +++++++++--------- .../STLArenaAllocatorTest.cpp | 10 +-- 3 files changed, 66 insertions(+), 66 deletions(-) diff --git a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp index 2854b970..25d75051 100644 --- a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp @@ -37,37 +37,37 @@ TEST_CASE ("Abstract Tree Test", "[common][data-structures]") tree.insertElements (std::vector { foods }); REQUIRE (tree.size() == 4); - SECTION ("Clear") - { - tree.clear(); - REQUIRE (tree.size() == 0); - } - - SECTION ("Insertion") - { - tree.insertElement ("almonds"); - REQUIRE (tree.size() == 5); - - { - const auto* a_node = tree.getRootNode().first_child; - REQUIRE (a_node->tag == "a"); - REQUIRE (a_node->first_child->leaf == "alfalfa"); - REQUIRE (a_node->first_child->next_sibling->leaf == "almonds"); - REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "apples"); - } - - tree.insertElement ("acai"); - REQUIRE (tree.size() == 6); - - { - const auto* a_node = tree.getRootNode().first_child; - REQUIRE (a_node->tag == "a"); - REQUIRE (a_node->first_child->leaf == "acai"); - REQUIRE (a_node->first_child->next_sibling->leaf == "alfalfa"); - REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "almonds"); - REQUIRE (a_node->first_child->next_sibling->next_sibling->next_sibling->leaf == "apples"); - } - } + // SECTION ("Clear") + // { + // tree.clear(); + // REQUIRE (tree.size() == 0); + // } + // + // SECTION ("Insertion") + // { + // tree.insertElement ("almonds"); + // REQUIRE (tree.size() == 5); + // + // { + // const auto* a_node = tree.getRootNode().first_child; + // REQUIRE (a_node->tag == "a"); + // REQUIRE (a_node->first_child->leaf == "alfalfa"); + // REQUIRE (a_node->first_child->next_sibling->leaf == "almonds"); + // REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "apples"); + // } + // + // tree.insertElement ("acai"); + // REQUIRE (tree.size() == 6); + // + // { + // const auto* a_node = tree.getRootNode().first_child; + // REQUIRE (a_node->tag == "a"); + // REQUIRE (a_node->first_child->leaf == "acai"); + // REQUIRE (a_node->first_child->next_sibling->leaf == "alfalfa"); + // REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "almonds"); + // REQUIRE (a_node->first_child->next_sibling->next_sibling->next_sibling->leaf == "apples"); + // } + // } // SECTION ("Remove One") // { diff --git a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp index e25b4c68..8385e1f8 100644 --- a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp @@ -66,34 +66,34 @@ TEST_CASE ("Enum Map Test", "[common][data-structures]") REQUIRE (map.empty()); } - // SECTION ("Iteration") - // { - // chowdsp::EnumMap map { - // { Food::Apple, 22 }, - // { Food::Green_Beans, 23 }, - // }; - // - // size_t iter = 0; - // for (const auto& [key, val] : std::as_const (map)) - // { - // jassert (iter < 2); - // if (iter == 0) - // { - // REQUIRE (key == Food::Apple); - // REQUIRE (val == 22); - // } - // else - // { - // REQUIRE (key == Food::Green_Beans); - // REQUIRE (val == 23); - // } - // ++iter; - // } - // - // iter = 0; - // for (auto [key, val] : map) - // val = (int) iter++; - // REQUIRE (map[Food::Apple] == 0); - // REQUIRE (map[Food::Green_Beans] == 1); - // } + SECTION ("Iteration") + { + chowdsp::EnumMap map { + { Food::Apple, 22 }, + { Food::Green_Beans, 23 }, + }; + + // size_t iter = 0; + // for (const auto& [key, val] : std::as_const (map)) + // { + // jassert (iter < 2); + // if (iter == 0) + // { + // REQUIRE (key == Food::Apple); + // REQUIRE (val == 22); + // } + // else + // { + // REQUIRE (key == Food::Green_Beans); + // REQUIRE (val == 23); + // } + // ++iter; + // } + // + // iter = 0; + // for (auto [key, val] : map) + // val = (int) iter++; + // REQUIRE (map[Food::Apple] == 0); + // REQUIRE (map[Food::Green_Beans] == 1); + } } diff --git a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp index bda81e56..62257fc7 100644 --- a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp @@ -9,11 +9,11 @@ TEST_CASE ("STL Arena Allocator Test", "[common][data-structures]") using Alloc = chowdsp::STLArenaAllocator; Alloc alloc { arena }; - using custom_vector = std::vector; - custom_vector vec { { 1, 2, 3, 4 }, alloc }; - REQUIRE (vec.size() == 4); - REQUIRE (vec.front() == 1); - REQUIRE (vec.back() == 4); + // using custom_vector = std::vector; + // custom_vector vec { { 1, 2, 3, 4 }, alloc }; + // REQUIRE (vec.size() == 4); + // REQUIRE (vec.front() == 1); + // REQUIRE (vec.back() == 4); // vec.push_back (5); // REQUIRE (vec.size() == 5); From 7f2a8c08ae3ff5f17fe2919394a5ecdc71870fbb Mon Sep 17 00:00:00 2001 From: jatin Date: Mon, 17 Jun 2024 18:49:22 -0700 Subject: [PATCH 05/10] Trying to break things again --- .../AbstractTreeTest.cpp | 12 +++---- .../EnumMapTest.cpp | 34 +++++++++---------- .../STLArenaAllocatorTest.cpp | 4 +-- 3 files changed, 25 insertions(+), 25 deletions(-) diff --git a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp index 25d75051..8bbca532 100644 --- a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp @@ -37,12 +37,12 @@ TEST_CASE ("Abstract Tree Test", "[common][data-structures]") tree.insertElements (std::vector { foods }); REQUIRE (tree.size() == 4); - // SECTION ("Clear") - // { - // tree.clear(); - // REQUIRE (tree.size() == 0); - // } - // + SECTION ("Clear") + { + tree.clear(); + REQUIRE (tree.size() == 0); + } + // SECTION ("Insertion") // { // tree.insertElement ("almonds"); diff --git a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp index 8385e1f8..04f72bdc 100644 --- a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp @@ -73,23 +73,23 @@ TEST_CASE ("Enum Map Test", "[common][data-structures]") { Food::Green_Beans, 23 }, }; - // size_t iter = 0; - // for (const auto& [key, val] : std::as_const (map)) - // { - // jassert (iter < 2); - // if (iter == 0) - // { - // REQUIRE (key == Food::Apple); - // REQUIRE (val == 22); - // } - // else - // { - // REQUIRE (key == Food::Green_Beans); - // REQUIRE (val == 23); - // } - // ++iter; - // } - // + size_t iter = 0; + for (const auto& [key, val] : std::as_const (map)) + { + jassert (iter < 2); + if (iter == 0) + { + REQUIRE (key == Food::Apple); + REQUIRE (val == 22); + } + else + { + REQUIRE (key == Food::Green_Beans); + REQUIRE (val == 23); + } + ++iter; + } + // iter = 0; // for (auto [key, val] : map) // val = (int) iter++; diff --git a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp index 62257fc7..a3163679 100644 --- a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp @@ -9,8 +9,8 @@ TEST_CASE ("STL Arena Allocator Test", "[common][data-structures]") using Alloc = chowdsp::STLArenaAllocator; Alloc alloc { arena }; - // using custom_vector = std::vector; - // custom_vector vec { { 1, 2, 3, 4 }, alloc }; + using custom_vector = std::vector; + custom_vector vec { { 1, 2, 3, 4 }, alloc }; // REQUIRE (vec.size() == 4); // REQUIRE (vec.front() == 1); // REQUIRE (vec.back() == 4); From ffbc2d7767c536f17247a130a35dd23267aa4b61 Mon Sep 17 00:00:00 2001 From: jatin Date: Mon, 17 Jun 2024 18:58:33 -0700 Subject: [PATCH 06/10] Still trying to break --- .../AbstractTreeTest.cpp | 50 +++++++++---------- .../EnumMapTest.cpp | 6 +-- .../STLArenaAllocatorTest.cpp | 6 +-- 3 files changed, 31 insertions(+), 31 deletions(-) diff --git a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp index 8bbca532..9ffc1dc3 100644 --- a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp @@ -43,31 +43,31 @@ TEST_CASE ("Abstract Tree Test", "[common][data-structures]") REQUIRE (tree.size() == 0); } - // SECTION ("Insertion") - // { - // tree.insertElement ("almonds"); - // REQUIRE (tree.size() == 5); - // - // { - // const auto* a_node = tree.getRootNode().first_child; - // REQUIRE (a_node->tag == "a"); - // REQUIRE (a_node->first_child->leaf == "alfalfa"); - // REQUIRE (a_node->first_child->next_sibling->leaf == "almonds"); - // REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "apples"); - // } - // - // tree.insertElement ("acai"); - // REQUIRE (tree.size() == 6); - // - // { - // const auto* a_node = tree.getRootNode().first_child; - // REQUIRE (a_node->tag == "a"); - // REQUIRE (a_node->first_child->leaf == "acai"); - // REQUIRE (a_node->first_child->next_sibling->leaf == "alfalfa"); - // REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "almonds"); - // REQUIRE (a_node->first_child->next_sibling->next_sibling->next_sibling->leaf == "apples"); - // } - // } + SECTION ("Insertion") + { + tree.insertElement ("almonds"); + REQUIRE (tree.size() == 5); + + // { + // const auto* a_node = tree.getRootNode().first_child; + // REQUIRE (a_node->tag == "a"); + // REQUIRE (a_node->first_child->leaf == "alfalfa"); + // REQUIRE (a_node->first_child->next_sibling->leaf == "almonds"); + // REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "apples"); + // } + // + // tree.insertElement ("acai"); + // REQUIRE (tree.size() == 6); + // + // { + // const auto* a_node = tree.getRootNode().first_child; + // REQUIRE (a_node->tag == "a"); + // REQUIRE (a_node->first_child->leaf == "acai"); + // REQUIRE (a_node->first_child->next_sibling->leaf == "alfalfa"); + // REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "almonds"); + // REQUIRE (a_node->first_child->next_sibling->next_sibling->next_sibling->leaf == "apples"); + // } + } // SECTION ("Remove One") // { diff --git a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp index 04f72bdc..3673e1f1 100644 --- a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp @@ -90,9 +90,9 @@ TEST_CASE ("Enum Map Test", "[common][data-structures]") ++iter; } - // iter = 0; - // for (auto [key, val] : map) - // val = (int) iter++; + iter = 0; + for (auto [key, val] : map) + val = static_cast (iter++); // REQUIRE (map[Food::Apple] == 0); // REQUIRE (map[Food::Green_Beans] == 1); } diff --git a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp index a3163679..bda81e56 100644 --- a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp @@ -11,9 +11,9 @@ TEST_CASE ("STL Arena Allocator Test", "[common][data-structures]") using custom_vector = std::vector; custom_vector vec { { 1, 2, 3, 4 }, alloc }; - // REQUIRE (vec.size() == 4); - // REQUIRE (vec.front() == 1); - // REQUIRE (vec.back() == 4); + REQUIRE (vec.size() == 4); + REQUIRE (vec.front() == 1); + REQUIRE (vec.back() == 4); // vec.push_back (5); // REQUIRE (vec.size() == 5); From 989da18db46d94bd71b884cf21220230a1fc5f2c Mon Sep 17 00:00:00 2001 From: jatin Date: Mon, 17 Jun 2024 19:12:15 -0700 Subject: [PATCH 07/10] closer --- .../AbstractTreeTest.cpp | 219 +++++++++--------- .../EnumMapTest.cpp | 4 +- .../STLArenaAllocatorTest.cpp | 8 +- 3 files changed, 117 insertions(+), 114 deletions(-) diff --git a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp index 9ffc1dc3..b35bc736 100644 --- a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp @@ -1,6 +1,8 @@ #include #include +#if ! JUCE_WINDOWS // @TODO + struct StringTree : chowdsp::AbstractTree { static Node& insert_string (std::string&& element, Node& parent_node, AbstractTree& tree) @@ -48,114 +50,115 @@ TEST_CASE ("Abstract Tree Test", "[common][data-structures]") tree.insertElement ("almonds"); REQUIRE (tree.size() == 5); - // { - // const auto* a_node = tree.getRootNode().first_child; - // REQUIRE (a_node->tag == "a"); - // REQUIRE (a_node->first_child->leaf == "alfalfa"); - // REQUIRE (a_node->first_child->next_sibling->leaf == "almonds"); - // REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "apples"); - // } - // - // tree.insertElement ("acai"); - // REQUIRE (tree.size() == 6); - // - // { - // const auto* a_node = tree.getRootNode().first_child; - // REQUIRE (a_node->tag == "a"); - // REQUIRE (a_node->first_child->leaf == "acai"); - // REQUIRE (a_node->first_child->next_sibling->leaf == "alfalfa"); - // REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "almonds"); - // REQUIRE (a_node->first_child->next_sibling->next_sibling->next_sibling->leaf == "apples"); - // } + { + const auto* a_node = tree.getRootNode().first_child; + REQUIRE (a_node->tag == "a"); + REQUIRE (a_node->first_child->leaf == "alfalfa"); + REQUIRE (a_node->first_child->next_sibling->leaf == "almonds"); + REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "apples"); + } + + tree.insertElement ("acai"); + REQUIRE (tree.size() == 6); + + { + const auto* a_node = tree.getRootNode().first_child; + REQUIRE (a_node->tag == "a"); + REQUIRE (a_node->first_child->leaf == "acai"); + REQUIRE (a_node->first_child->next_sibling->leaf == "alfalfa"); + REQUIRE (a_node->first_child->next_sibling->next_sibling->leaf == "almonds"); + REQUIRE (a_node->first_child->next_sibling->next_sibling->next_sibling->leaf == "apples"); + } + } + + SECTION ("Remove One") + { + tree.removeElement ("beets"); + REQUIRE (tree.size() == 3); + + const auto* d_node = tree.getRootNode().first_child->next_sibling; + REQUIRE (d_node->tag == "d"); + } + + SECTION ("Remove From Start of Sub-Tree") + { + tree.removeElement ("alfalfa"); + REQUIRE (tree.size() == 3); + + const auto* a_node = tree.getRootNode().first_child; + REQUIRE (a_node->first_child->leaf == "apples"); + } + + SECTION ("Remove From End of Sub-Tree") + { + tree.removeElement ("apples"); + REQUIRE (tree.size() == 3); + + const auto* a_node = tree.getRootNode().first_child; + REQUIRE (a_node->last_child->leaf == "alfalfa"); + } + + SECTION ("Remove Last Node in Sub-Tree") + { + tree.removeElement ("donuts"); + REQUIRE (tree.size() == 3); + + const auto* b_node = tree.getRootNode().last_child; + REQUIRE (b_node->tag == "b"); + } + + SECTION ("Remove Multiple") + { + tree.removeElements ([] (const std::string& el) + { return el.find ('t') != std::string::npos; }); + REQUIRE (tree.size() == 2); + + REQUIRE (tree.getRootNode().first_child == tree.getRootNode().last_child); + REQUIRE (tree.getRootNode().first_child->tag == "a"); } - // SECTION ("Remove One") - // { - // tree.removeElement ("beets"); - // REQUIRE (tree.size() == 3); - // - // const auto* d_node = tree.getRootNode().first_child->next_sibling; - // REQUIRE (d_node->tag == "d"); - // } - // - // SECTION ("Remove From Start of Sub-Tree") - // { - // tree.removeElement ("alfalfa"); - // REQUIRE (tree.size() == 3); - // - // const auto* a_node = tree.getRootNode().first_child; - // REQUIRE (a_node->first_child->leaf == "apples"); - // } - // - // SECTION ("Remove From End of Sub-Tree") - // { - // tree.removeElement ("apples"); - // REQUIRE (tree.size() == 3); - // - // const auto* a_node = tree.getRootNode().first_child; - // REQUIRE (a_node->last_child->leaf == "alfalfa"); - // } - // - // SECTION ("Remove Last Node in Sub-Tree") - // { - // tree.removeElement ("donuts"); - // REQUIRE (tree.size() == 3); - // - // const auto* b_node = tree.getRootNode().last_child; - // REQUIRE (b_node->tag == "b"); - // } - - // SECTION ("Remove Multiple") - // { - // tree.removeElements ([] (const std::string& el) - // { return el.find ('t') != std::string::npos; }); - // REQUIRE (tree.size() == 2); - // - // REQUIRE (tree.getRootNode().first_child == tree.getRootNode().last_child); - // REQUIRE (tree.getRootNode().first_child->tag == "a"); - // } - // - // SECTION ("Remove All") - // { - // tree.removeElements ([] (const std::string& el) - // { return ! el.empty(); }); - // REQUIRE (tree.size() == 0); - // - // tree.insertElement ("mussels"); - // REQUIRE (tree.size() == 1); - // REQUIRE (tree.getRootNode().first_child->tag == "m"); - // REQUIRE (tree.getRootNode().first_child->first_child->leaf == "mussels"); - // - // auto* found = tree.findElement ("mussels"); - // REQUIRE (found != nullptr); - // } - // - // SECTION ("Find Success") - // { - // auto* found = std::as_const (tree).findElement ("apples"); - // jassert (found != nullptr); - // } - // - // SECTION ("Find Fail") - // { - // [[maybe_unused]] auto* found = std::as_const (tree).findElement ("bologna"); - // jassert (found == nullptr); - // } - // - // SECTION ("To Uppercase") - // { - // tree.doForAllElements ( - // [] (std::string& str) - // { - // for (auto& c : str) - // c = static_cast (std::toupper (static_cast (c))); - // }); - // - // std::as_const (tree).doForAllElements ( - // [] (const std::string& str) - // { - // for (auto& c : str) - // REQUIRE (((c >= 'A') && (c <= 'Z'))); - // }); - // } + SECTION ("Remove All") + { + tree.removeElements ([] (const std::string& el) + { return ! el.empty(); }); + REQUIRE (tree.size() == 0); + + tree.insertElement ("mussels"); + REQUIRE (tree.size() == 1); + REQUIRE (tree.getRootNode().first_child->tag == "m"); + REQUIRE (tree.getRootNode().first_child->first_child->leaf == "mussels"); + + auto* found = tree.findElement ("mussels"); + REQUIRE (found != nullptr); + } + + SECTION ("Find Success") + { + auto* found = std::as_const (tree).findElement ("apples"); + jassert (found != nullptr); + } + + SECTION ("Find Fail") + { + [[maybe_unused]] auto* found = std::as_const (tree).findElement ("bologna"); + jassert (found == nullptr); + } + + SECTION ("To Uppercase") + { + tree.doForAllElements ( + [] (std::string& str) + { + for (auto& c : str) + c = static_cast (std::toupper (static_cast (c))); + }); + + std::as_const (tree).doForAllElements ( + [] (const std::string& str) + { + for (auto& c : str) + REQUIRE (((c >= 'A') && (c <= 'Z'))); + }); + } } +#endif diff --git a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp index 3673e1f1..4dd90ef4 100644 --- a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp @@ -93,7 +93,7 @@ TEST_CASE ("Enum Map Test", "[common][data-structures]") iter = 0; for (auto [key, val] : map) val = static_cast (iter++); - // REQUIRE (map[Food::Apple] == 0); - // REQUIRE (map[Food::Green_Beans] == 1); + REQUIRE (map[Food::Apple] == 0); + REQUIRE (map[Food::Green_Beans] == 1); } } diff --git a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp index bda81e56..5c7d333d 100644 --- a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp @@ -15,10 +15,10 @@ TEST_CASE ("STL Arena Allocator Test", "[common][data-structures]") REQUIRE (vec.front() == 1); REQUIRE (vec.back() == 4); - // vec.push_back (5); - // REQUIRE (vec.size() == 5); - // REQUIRE (vec.back() == 5); - // + vec.push_back (5); + REQUIRE (vec.size() == 5); + REQUIRE (vec.back() == 5); + // vec.erase (vec.begin()); // REQUIRE (vec.size() == 4); // vec.insert (vec.begin(), 0); From 38c68a81622132e0ac20cbf24c01b62d0baf10bf Mon Sep 17 00:00:00 2001 From: jatin Date: Mon, 17 Jun 2024 19:21:21 -0700 Subject: [PATCH 08/10] This should do it --- .../STLArenaAllocatorTest.cpp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp index 5c7d333d..df8a9f21 100644 --- a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp @@ -1,6 +1,8 @@ #include #include +#if ! JUCE_WINDOWS // @TODO + TEST_CASE ("STL Arena Allocator Test", "[common][data-structures]") { using Arena = chowdsp::ArenaAllocator<>; @@ -19,9 +21,11 @@ TEST_CASE ("STL Arena Allocator Test", "[common][data-structures]") REQUIRE (vec.size() == 5); REQUIRE (vec.back() == 5); - // vec.erase (vec.begin()); - // REQUIRE (vec.size() == 4); - // vec.insert (vec.begin(), 0); - // REQUIRE (vec.size() == 5); - // REQUIRE (vec.front() == 0); + vec.erase (vec.begin()); + REQUIRE (vec.size() == 4); + vec.insert (vec.begin(), 0); + REQUIRE (vec.size() == 5); + REQUIRE (vec.front() == 0); } + +#endif From d40dacaf9104cd3d4dd9aa9d524ef6e5c8cac7f6 Mon Sep 17 00:00:00 2001 From: jatin Date: Mon, 17 Jun 2024 20:03:05 -0700 Subject: [PATCH 09/10] One more time --- tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp index 4dd90ef4..fd6133e4 100644 --- a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp @@ -93,7 +93,9 @@ TEST_CASE ("Enum Map Test", "[common][data-structures]") iter = 0; for (auto [key, val] : map) val = static_cast (iter++); +#if ! JUCE_WINDOWS // @TODO REQUIRE (map[Food::Apple] == 0); REQUIRE (map[Food::Green_Beans] == 1); +#endif } } From 60c4de2827229d515794b1c1f84524fed03b3c3f Mon Sep 17 00:00:00 2001 From: jatin Date: Mon, 17 Jun 2024 22:07:55 -0700 Subject: [PATCH 10/10] More CI fixes --- .../Allocators/chowdsp_STLArenaAllocator.h | 2 +- .../Structures/chowdsp_AbstractTree.cpp | 7 ++++--- .../chowdsp_data_structures/Structures/chowdsp_EnumMap.h | 2 +- .../chowdsp_data_structures_test/AbstractTreeTest.cpp | 3 --- .../chowdsp_data_structures_test/EnumMapTest.cpp | 2 -- .../chowdsp_data_structures_test/STLArenaAllocatorTest.cpp | 4 ---- 6 files changed, 6 insertions(+), 14 deletions(-) diff --git a/modules/common/chowdsp_data_structures/Allocators/chowdsp_STLArenaAllocator.h b/modules/common/chowdsp_data_structures/Allocators/chowdsp_STLArenaAllocator.h index b41cef89..df0e705f 100644 --- a/modules/common/chowdsp_data_structures/Allocators/chowdsp_STLArenaAllocator.h +++ b/modules/common/chowdsp_data_structures/Allocators/chowdsp_STLArenaAllocator.h @@ -28,7 +28,7 @@ struct STLArenaAllocator T* allocate (std::size_t n) { - return static_cast (arena.allocate_bytes (n, alignof (T))); + return static_cast (arena.allocate_bytes (n * sizeof (T), alignof (T))); } void deallocate (T*, std::size_t) const diff --git a/modules/common/chowdsp_data_structures/Structures/chowdsp_AbstractTree.cpp b/modules/common/chowdsp_data_structures/Structures/chowdsp_AbstractTree.cpp index dcd95bf0..3b49285e 100644 --- a/modules/common/chowdsp_data_structures/Structures/chowdsp_AbstractTree.cpp +++ b/modules/common/chowdsp_data_structures/Structures/chowdsp_AbstractTree.cpp @@ -10,7 +10,7 @@ template AbstractTree::~AbstractTree() { doForAllNodes ([] (Node& node) - { node.~Node(); }); + { node.leaf.reset(); }); } template @@ -108,7 +108,7 @@ void AbstractTree::removeNode (Node& node) node.parent->last_child = node.prev_sibling; } - node.~Node(); + node.leaf.reset(); } template @@ -150,9 +150,10 @@ template void AbstractTree::clear() { doForAllNodes ([] (Node& node) - { node.~Node(); }); + { node.leaf.reset(); }); allocator.reset (64 * sizeof (Node)); count = 0; + root_node = {}; } template diff --git a/modules/common/chowdsp_data_structures/Structures/chowdsp_EnumMap.h b/modules/common/chowdsp_data_structures/Structures/chowdsp_EnumMap.h index 3095b583..cd0c2190 100644 --- a/modules/common/chowdsp_data_structures/Structures/chowdsp_EnumMap.h +++ b/modules/common/chowdsp_data_structures/Structures/chowdsp_EnumMap.h @@ -126,7 +126,7 @@ struct EnumMap { ++index; ++iter; - } while (! iter->has_value() && index < std::tuple_size_v); + } while (index < std::tuple_size_v && ! iter->has_value()); if (index < std::tuple_size_v) key = magic_enum::enum_value (index); diff --git a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp index b35bc736..d52487f0 100644 --- a/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/AbstractTreeTest.cpp @@ -1,8 +1,6 @@ #include #include -#if ! JUCE_WINDOWS // @TODO - struct StringTree : chowdsp::AbstractTree { static Node& insert_string (std::string&& element, Node& parent_node, AbstractTree& tree) @@ -161,4 +159,3 @@ TEST_CASE ("Abstract Tree Test", "[common][data-structures]") }); } } -#endif diff --git a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp index fd6133e4..4dd90ef4 100644 --- a/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/EnumMapTest.cpp @@ -93,9 +93,7 @@ TEST_CASE ("Enum Map Test", "[common][data-structures]") iter = 0; for (auto [key, val] : map) val = static_cast (iter++); -#if ! JUCE_WINDOWS // @TODO REQUIRE (map[Food::Apple] == 0); REQUIRE (map[Food::Green_Beans] == 1); -#endif } } diff --git a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp index df8a9f21..017afca9 100644 --- a/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp +++ b/tests/common_tests/chowdsp_data_structures_test/STLArenaAllocatorTest.cpp @@ -1,8 +1,6 @@ #include #include -#if ! JUCE_WINDOWS // @TODO - TEST_CASE ("STL Arena Allocator Test", "[common][data-structures]") { using Arena = chowdsp::ArenaAllocator<>; @@ -27,5 +25,3 @@ TEST_CASE ("STL Arena Allocator Test", "[common][data-structures]") REQUIRE (vec.size() == 5); REQUIRE (vec.front() == 0); } - -#endif