migrating to googletest
This commit is contained in:
parent
9d1fc30857
commit
473f67e907
|
@ -155,7 +155,7 @@ static void confgiureFordAspireTriggerShape(TriggerShape * s) {
|
||||||
|
|
||||||
assertEqualsM("expecting 0", 0, s->wave.findAngleMatch(53.747 / 720.0, s->getSize()));
|
assertEqualsM("expecting 0", 0, s->wave.findAngleMatch(53.747 / 720.0, s->getSize()));
|
||||||
assertEqualsM("expecting not found", -1, s->wave.findAngleMatch(53 / 720.0, s->getSize()));
|
assertEqualsM("expecting not found", -1, s->wave.findAngleMatch(53 / 720.0, s->getSize()));
|
||||||
assertEquals(7, s->wave.findAngleMatch(588.045 / 720.0, s->getSize()));
|
ASSERT_EQ(7, s->wave.findAngleMatch(588.045 / 720.0, s->getSize()));
|
||||||
|
|
||||||
assertEqualsM("expecting 0", 0, s->wave.findInsertionAngle(23.747 / 720.0, s->getSize()));
|
assertEqualsM("expecting 0", 0, s->wave.findInsertionAngle(23.747 / 720.0, s->getSize()));
|
||||||
assertEqualsM("expecting 1", 1, s->wave.findInsertionAngle(63.747 / 720.0, s->getSize()));
|
assertEqualsM("expecting 1", 1, s->wave.findInsertionAngle(63.747 / 720.0, s->getSize()));
|
||||||
|
|
|
@ -36,7 +36,7 @@ TEST(sensors, tps) {
|
||||||
engineConfiguration->tpsMax = 193;
|
engineConfiguration->tpsMax = 193;
|
||||||
engineConfiguration->tpsMin = 43;
|
engineConfiguration->tpsMin = 43;
|
||||||
|
|
||||||
assertEquals(49.3333, getTpsValue(4 * 117 PASS_ENGINE_PARAMETER_SUFFIX));
|
ASSERT_NEAR(49.3333, getTpsValue(4 * 117 PASS_ENGINE_PARAMETER_SUFFIX), EPS4D);
|
||||||
|
|
||||||
|
|
||||||
engineConfiguration->tpsMax = 43;
|
engineConfiguration->tpsMax = 43;
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
|
|
||||||
TEST(util, crc) {
|
TEST(util, crc) {
|
||||||
ASSERT_EQ(4, efiRound(4.4, 1));
|
ASSERT_EQ(4, efiRound(4.4, 1));
|
||||||
assertEquals(1.2, efiRound(1.2345, 0.1));
|
ASSERT_FLOAT_EQ(1.2, efiRound(1.2345, 0.1));
|
||||||
|
|
||||||
print("*************************************** testCrc\r\n");
|
print("*************************************** testCrc\r\n");
|
||||||
|
|
||||||
|
|
|
@ -45,10 +45,6 @@ void assertEqualsM(const char *msg, float expected, float actual) {
|
||||||
assertEqualsM2(msg, expected, actual, 0.0001);
|
assertEqualsM2(msg, expected, actual, 0.0001);
|
||||||
}
|
}
|
||||||
|
|
||||||
void assertEquals(float expected, float actual) {
|
|
||||||
assertEqualsM("", expected, actual);
|
|
||||||
}
|
|
||||||
|
|
||||||
void assertTrueM(const char *msg, float actual) {
|
void assertTrueM(const char *msg, float actual) {
|
||||||
assertEqualsM(msg, TRUE, actual);
|
assertEqualsM(msg, TRUE, actual);
|
||||||
}
|
}
|
||||||
|
|
|
@ -23,7 +23,6 @@ void assertEqualsM(const char *msg, float expected, float actual);
|
||||||
void assertEqualsLM(const char *msg, long expected, long actual);
|
void assertEqualsLM(const char *msg, long expected, long actual);
|
||||||
void assertEqualsM4(const char *prefix, const char *msg, float expected, float actual);
|
void assertEqualsM4(const char *prefix, const char *msg, float expected, float actual);
|
||||||
void assertEqualsM5(const char *prefix, const char *message, float expected, float actual, float EPS);
|
void assertEqualsM5(const char *prefix, const char *message, float expected, float actual, float EPS);
|
||||||
void assertEquals(float expected, float actual);
|
|
||||||
void assertTrueM(const char *msg, float actual);
|
void assertTrueM(const char *msg, float actual);
|
||||||
void assertFalseM(const char *msg, float actual);
|
void assertFalseM(const char *msg, float actual);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue