From 812fa8f3cb0a665f95da51549bda661f3d5ea430 Mon Sep 17 00:00:00 2001 From: crankyoldgit Date: Sat, 6 Nov 2021 20:38:40 +1000 Subject: [PATCH] Additional unit test for `getModel()` Ref: https://github.com/crankyoldgit/IRremoteESP8266/issues/1573#issuecomment-962362540 --- test/ir_Mirage_test.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/test/ir_Mirage_test.cpp b/test/ir_Mirage_test.cpp index cf73f3135..ad08918e2 100644 --- a/test/ir_Mirage_test.cpp +++ b/test/ir_Mirage_test.cpp @@ -581,4 +581,11 @@ TEST(TestMirageAcClass, getModel) { 0x56, 0x74, 0x00, 0x00, 0x12, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1D}; EXPECT_EQ(mirage_ac_remote_model_t::KKG29AC1, IRMirageAc::getModel(KKG29AC1)); + + // https://github.com/crankyoldgit/IRremoteESP8266/issues/1573#issuecomment-962362540 + const uint8_t KKG29AC1_2[kMirageStateLength] = { + 0x56, 0x72, 0x00, 0x00, 0x23, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19}; + EXPECT_EQ(mirage_ac_remote_model_t::KKG29AC1, + IRMirageAc::getModel(KKG29AC1_2)); }