updated test to exclude non allowed clusters
Build on RHEL9 / build (push) Successful in 2m36s
Build on RHEL8 / build (push) Successful in 3m30s
Run tests using data on local RHEL8 / build (push) Failing after 4m2s

This commit is contained in:
Erik Frojdh
2026-09-02 12:25:19 +02:00
parent d6388661bc
commit 331bac2c27
+13 -8
View File
@@ -24,8 +24,9 @@ TEST_CASE("Test sum of Cluster", "[cluster]") {
using ClusterTypes = std::variant<Cluster<int, 2, 2>, Cluster<int, 3, 3>,
Cluster<int, 5, 5>, Cluster<int, 2, 3>>;
using ClusterTypesLargerThan2x2 =
std::variant<Cluster<int, 3, 3>, Cluster<int, 4, 4>, Cluster<int, 5, 5>>;
using OddClusterTypesAtLeast3x3 =
std::variant<Cluster<int, 3, 3>, Cluster<int, 3, 5>, Cluster<int, 5, 3>,
Cluster<int, 5, 5>>;
TEST_CASE("Test reduce to 2x2 Cluster", "[cluster]") {
auto [cluster, expected_reduced_cluster] = GENERATE(
@@ -68,14 +69,18 @@ TEST_CASE("Test reduce to 2x2 Cluster", "[cluster]") {
TEST_CASE("Test reduce to 3x3 Cluster", "[cluster]") {
auto [cluster, expected_reduced_cluster] = GENERATE(
std::make_tuple(ClusterTypesLargerThan2x2{Cluster<int, 3, 3>{
std::make_tuple(OddClusterTypesAtLeast3x3{Cluster<int, 3, 3>{
5, 5, {1, 1, 1, 1, 3, 1, 1, 1, 1}}},
Cluster<int, 3, 3>{5, 5, {1, 1, 1, 1, 3, 1, 1, 1, 1}}),
std::make_tuple(
ClusterTypesLargerThan2x2{Cluster<int, 4, 4>{
5, 5, {2, 2, 1, 1, 2, 2, 1, 1, 1, 1, 3, 1, 1, 1, 1, 1}}},
Cluster<int, 3, 3>{5, 5, {2, 1, 1, 1, 3, 1, 1, 1, 1}}),
std::make_tuple(ClusterTypesLargerThan2x2{Cluster<int, 5, 5>{
OddClusterTypesAtLeast3x3{Cluster<int, 3, 5>{
5, 5, {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14}}},
Cluster<int, 3, 3>{5, 5, {3, 4, 5, 6, 7, 8, 9, 10, 11}}),
std::make_tuple(
OddClusterTypesAtLeast3x3{Cluster<int, 5, 3>{
5, 5, {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14}}},
Cluster<int, 3, 3>{5, 5, {1, 2, 3, 6, 7, 8, 11, 12, 13}}),
std::make_tuple(OddClusterTypesAtLeast3x3{Cluster<int, 5, 5>{
5, 5, {1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 2, 3,
1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1}}},
Cluster<int, 3, 3>{5, 5, {2, 1, 1, 2, 3, 1, 2, 1, 1}}));
@@ -89,4 +94,4 @@ TEST_CASE("Test reduce to 3x3 Cluster", "[cluster]") {
CHECK(std::equal(reduced_cluster.data.begin(),
reduced_cluster.data.begin() + 9,
expected_reduced_cluster.data.begin()));
}
}