Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Partially working tests on macOS #2076

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/IRutils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -262,8 +262,8 @@ String resultToSourceCode(const decode_results * const results) {
// "uint32_t address = 0xDEADBEEF;\n"
// "uint32_t command = 0xDEADBEEF;\n"
// "uint64_t data = 0xDEADBEEFDEADBEEF;" = ~116 chars max.
output.reserve(55 + (length * 7) + hasState ? 25 + (results->bits / 8) * 6
: 116);
output.reserve(55 + (length * 7) + (hasState ? 25 + (results->bits / 8) * 6
: 116));
// Start declaration
output += F("uint16_t "); // variable type
output += F("rawData["); // array name
Expand Down
4 changes: 2 additions & 2 deletions src/ir_Coolix.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,8 @@ void IRCoolixAC::send(const uint16_t repeat) {
// Typically repeat is `kCoolixDefaultRepeat` which is `1`, so this allows
// it to be 0 normally for this command, and allows additional repeats if
// requested rather always 0 for that command.
_irsend.sendCOOLIX(getRaw(), kCoolixBits, repeat - (getSwingVStep() &&
repeat > 0) ? 1 : 0);
_irsend.sendCOOLIX(getRaw(), kCoolixBits, repeat - ((getSwingVStep() &&
repeat > 0) ? 1 : 0));
// make sure to remove special state from the internal state
// after command has being transmitted.
recoverSavedState();
Expand Down
1 change: 1 addition & 0 deletions src/ir_LG.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,7 @@ void IRLgAc::stateReset(void) {
_light = true;
_swingv = kLgAcSwingVOff;
_swingh = false;
_swingh_prev = false;
for (uint8_t i = 0; i < kLgAcSwingVMaxVanes; i++)
_vaneswingv[i] = 0; // Reset to an unused value.
updateSwingPrev();
Expand Down
8 changes: 4 additions & 4 deletions test/ir_Argo_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -509,7 +509,7 @@ TEST_P(TestArgoConfigViaIRAc_Positive,
EXPECT_EQ(state.command, r.command);
}

INSTANTIATE_TEST_CASE_P(
INSTANTIATE_TEST_SUITE_P(
TestIrAc,
TestArgoConfigViaIRAc_Positive,
::testing::Values(
Expand Down Expand Up @@ -546,7 +546,7 @@ TEST_P(TestArgoConfigViaIRAc_Negative,
ASSERT_EQ(nullptr, irac._lastDecodeResults); // nothing got sent
}

INSTANTIATE_TEST_CASE_P(
INSTANTIATE_TEST_SUITE_P(
TestIrAc,
TestArgoConfigViaIRAc_Negative,
::testing::Values(
Expand All @@ -565,7 +565,7 @@ INSTANTIATE_TEST_CASE_P(

using IRArgoACBase_typelist = ::testing::Types<ArgoProtocol, ArgoProtocolWREM3>;
template<class> struct TestArgoACBaseClass : public testing::Test {};
TYPED_TEST_CASE(TestArgoACBaseClass, IRArgoACBase_typelist);
TYPED_TEST_SUITE(TestArgoACBaseClass, IRArgoACBase_typelist);


TYPED_TEST(TestArgoACBaseClass, SetAndGetTemp) {
Expand Down Expand Up @@ -1520,7 +1520,7 @@ TEST_P(TestArgoE2E, RealExampleCommands) {
}

// Test cases
INSTANTIATE_TEST_CASE_P(
INSTANTIATE_TEST_SUITE_P(
TestDecodeArgo,
TestArgoE2E,
::testing::Values(
Expand Down
4 changes: 2 additions & 2 deletions test/ir_Gorenje_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ TEST_P(TestDecodeGorenjeSyntheticSendTestFixture, SyntheticExample) {
EXPECT_FALSE(irsend.capture.repeat);
}

INSTANTIATE_TEST_CASE_P(
INSTANTIATE_TEST_SUITE_P(
TestDecodeGorenje,
TestDecodeGorenjeSyntheticSendTestFixture,
::testing::Values(0x2, 0x8, 0x4, 0x10, 0x20, 0x1));
Expand Down Expand Up @@ -112,7 +112,7 @@ TEST_P(TestDecodeGorenjeReceiveTestFixture, RealExample) {
EXPECT_FALSE(irsend.capture.repeat);
}

INSTANTIATE_TEST_CASE_P(
INSTANTIATE_TEST_SUITE_P(
TestDecodeGorenje,
TestDecodeGorenjeReceiveTestFixture,
::testing::Values(
Expand Down
2 changes: 1 addition & 1 deletion test/ir_Hitachi_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1831,7 +1831,7 @@ TEST(TestIRHitachiAc1Class, FanSpeedInDryMode) {
ac.setPower(true);
ac.setPowerToggle(true);
ac.setMode(kHitachiAc1Dry);
ac.setTemp(22.5);
ac.setTemp(22);
ac.setFan(kHitachiAc1FanLow);
ac.setSwingV(false);
ac.setSwingH(false);
Expand Down