Skip to content

Commit 1aa62cb

Browse files
committed
Enables legacy code compilation
The changes encapsulate the matrix tests within an `#ifdef` block, allowing conditional compilation based on whether `OMATH_ENABLE_LEGACY` is defined. This enables the legacy code to be compiled only when needed.
1 parent 8e41177 commit 1aa62cb

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

tests/general/unit_test_matrix.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
//
22
// Created by vlad on 5/18/2024.
33
//
4+
5+
#ifdef OMATH_ENABLE_LEGACY
6+
47
#include <gtest/gtest.h>
58
#include <omath/matrix.hpp>
69
#include "omath/vector3.hpp"
@@ -177,4 +180,5 @@ TEST_F(UnitTestMatrix, AssignmentOperator_Move)
177180
EXPECT_FLOAT_EQ(m3.at(0, 0), 1.0f);
178181
EXPECT_EQ(m2.row_count(), 0); // m2 should be empty after the move
179182
EXPECT_EQ(m2.columns_count(), 0);
180-
}
183+
}
184+
#endif

0 commit comments

Comments
 (0)