Skip to content

Commit

Permalink
std::abs -> abs
Browse files Browse the repository at this point in the history
  • Loading branch information
TomSaw committed Dec 13, 2021
1 parent f7e97cd commit c9d4d44
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions test/modm/math/saturation/saturation_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ SaturationTest::testSigned8bit()
TEST_ASSERT_EQUALS(x.getValue(), -10);

y = -100;
/* x = std::abs(y);
TEST_ASSERT_EQUALS(x.getValue(), 100); */
x = abs(y);
TEST_ASSERT_EQUALS(x.getValue(), 100);

x = y;
x.absolute();
Expand Down Expand Up @@ -133,7 +133,7 @@ SaturationTest::testUnsigned8bit()
TEST_ASSERT_EQUALS(x.getValue(), 0U);

y = 200;
x = std::abs(y);
x = abs(y);
TEST_ASSERT_EQUALS(x.getValue(), 200U);

x = y;
Expand Down Expand Up @@ -193,7 +193,7 @@ SaturationTest::testSigned16bit()
TEST_ASSERT_EQUALS(x.getValue(), 10000);

y = -20000;
x = std::abs(y);
x = abs(y);
TEST_ASSERT_EQUALS(x.getValue(), 20000);

x = y;
Expand Down Expand Up @@ -257,8 +257,8 @@ SaturationTest::testUnsigned16bit()
TEST_ASSERT_EQUALS(x.getValue(), 0U);

y = 20000;
/* x = std::abs(y);
TEST_ASSERT_EQUALS(x.getValue(), 20000U); */
x = abs(y);
TEST_ASSERT_EQUALS(x.getValue(), 20000U);

x = y;
x.absolute();
Expand Down

0 comments on commit c9d4d44

Please sign in to comment.