action: use PDI type
Rather than define our own enumeration for the LED Actions,
reuse the one from Led.Physical's dbus interface.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I4615bed9e87c61d2632fe790bd50892a7f51e2ab
diff --git a/test/led-test-map.hpp b/test/led-test-map.hpp
index 983fad5..86b3587 100644
--- a/test/led-test-map.hpp
+++ b/test/led-test-map.hpp
@@ -8,8 +8,8 @@
singleLedOn = {
{"/xyz/openbmc_project/ledmanager/groups/SingleLed",
{
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
}},
};
@@ -17,8 +17,8 @@
singleLedBlink = {
{"/xyz/openbmc_project/ledmanager/groups/SingleLed",
{
- {"One", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
}},
};
@@ -26,8 +26,8 @@
singleLedBlinkOverrideOn = {
{"/xyz/openbmc_project/ledmanager/groups/SingleLed",
{
- {"One", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
};
@@ -35,12 +35,12 @@
multipleLedsOn = {
{"/xyz/openbmc_project/ledmanager/groups/MultipleLeds",
{
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
};
@@ -48,12 +48,12 @@
multipleLedsBlink = {
{"/xyz/openbmc_project/ledmanager/groups/MultipleLeds",
{
- {"One", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
}},
};
@@ -61,16 +61,16 @@
multipleLedsOnAndBlink = {
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsMix",
{
- {"One", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Two", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
}},
};
@@ -78,21 +78,21 @@
twoGroupsWithDistinctLEDsOn = {
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsASet",
{
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Two", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
}},
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsBSet",
{
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Six", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
};
@@ -100,21 +100,21 @@
twoGroupsWithOneComonLEDOn = {
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsASet",
{
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsBSet",
{
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
};
@@ -122,21 +122,21 @@
twoGroupsWithOneComonLEDOnOneLEDBlinkPriority = {
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsASet",
{
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
}},
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsBSet",
{
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Six", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
};
@@ -144,21 +144,21 @@
twoGroupsWithOneComonLEDOnPriority = {
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsASet",
{
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsBSet",
{
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
};
@@ -166,23 +166,23 @@
twoGroupsWithMultiplComonLEDOn = {
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsASet",
{
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsBSet",
{
- {"Two", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Seven", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Seven", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
};
@@ -190,25 +190,25 @@
twoGroupsWithMultipleComonLEDInDifferentState = {
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsASet",
{
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsBSet",
{
- {"Two", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
}},
};
@@ -216,28 +216,28 @@
twoGroupsWithMultipleComonLEDInDifferentStateDiffPriority = {
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsASet",
{
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Ten", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Ten", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
}},
{"/xyz/openbmc_project/ledmanager/groups/MultipleLedsBSet",
{
- {"Two", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Ten", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Ten", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
}},
};
diff --git a/test/utest-led-json.cpp b/test/utest-led-json.cpp
index e2d8edb..b9b6e24 100644
--- a/test/utest-led-json.cpp
+++ b/test/utest-led-json.cpp
@@ -23,36 +23,36 @@
for (const auto& group : bmcBootedActions)
{
ASSERT_EQ(group.name, "heartbeat");
- ASSERT_EQ(group.action, phosphor::led::Layout::On);
+ ASSERT_EQ(group.action, phosphor::led::Layout::Action::On);
ASSERT_EQ(group.dutyOn, 50);
ASSERT_EQ(group.period, 0);
- ASSERT_EQ(group.priority, phosphor::led::Layout::Blink);
+ ASSERT_EQ(group.priority, phosphor::led::Layout::Action::Blink);
}
for (const auto& group : powerOnActions)
{
ASSERT_EQ(group.name, "power");
- ASSERT_EQ(group.action, phosphor::led::Layout::On);
+ ASSERT_EQ(group.action, phosphor::led::Layout::Action::On);
ASSERT_EQ(group.dutyOn, 50);
ASSERT_EQ(group.period, 0);
- ASSERT_EQ(group.priority, phosphor::led::Layout::On);
+ ASSERT_EQ(group.priority, phosphor::led::Layout::Action::On);
}
for (const auto& group : enclosureIdentifyActions)
{
if (group.name == "front_id")
{
- ASSERT_EQ(group.action, phosphor::led::Layout::Blink);
+ ASSERT_EQ(group.action, phosphor::led::Layout::Action::Blink);
ASSERT_EQ(group.dutyOn, 50);
ASSERT_EQ(group.period, 1000);
- ASSERT_EQ(group.priority, phosphor::led::Layout::Blink);
+ ASSERT_EQ(group.priority, phosphor::led::Layout::Action::Blink);
}
else if (group.name == "rear_id")
{
- ASSERT_EQ(group.action, phosphor::led::Layout::Blink);
+ ASSERT_EQ(group.action, phosphor::led::Layout::Action::Blink);
ASSERT_EQ(group.dutyOn, 50);
ASSERT_EQ(group.period, 1000);
- ASSERT_EQ(group.priority, phosphor::led::Layout::Blink);
+ ASSERT_EQ(group.priority, phosphor::led::Layout::Action::Blink);
}
else
{
@@ -70,20 +70,25 @@
TEST(validatePriority, testGoodPriority)
{
PriorityMap priorityMap{};
- validatePriority("heartbeat", phosphor::led::Layout::Blink, priorityMap);
- validatePriority("power", phosphor::led::Layout::On, priorityMap);
+ validatePriority("heartbeat", phosphor::led::Layout::Action::Blink,
+ priorityMap);
+ validatePriority("power", phosphor::led::Layout::Action::On, priorityMap);
- ASSERT_EQ(priorityMap.at("heartbeat"), phosphor::led::Layout::Blink);
- ASSERT_EQ(priorityMap.at("power"), phosphor::led::Layout::On);
+ ASSERT_EQ(priorityMap.at("heartbeat"),
+ phosphor::led::Layout::Action::Blink);
+ ASSERT_EQ(priorityMap.at("power"), phosphor::led::Layout::Action::On);
}
TEST(validatePriority, testBadPriority)
{
PriorityMap priorityMap{};
- validatePriority("heartbeat", phosphor::led::Layout::Blink, priorityMap);
+ validatePriority("heartbeat", phosphor::led::Layout::Action::Blink,
+ priorityMap);
- ASSERT_EQ(priorityMap.at("heartbeat"), phosphor::led::Layout::Blink);
- ASSERT_THROW(
- validatePriority("heartbeat", phosphor::led::Layout::On, priorityMap),
- std::runtime_error);
+ ASSERT_EQ(priorityMap.at("heartbeat"),
+ phosphor::led::Layout::Action::Blink);
+ ASSERT_THROW(validatePriority("heartbeat",
+ phosphor::led::Layout::Action::On,
+ priorityMap),
+ std::runtime_error);
}
\ No newline at end of file
diff --git a/test/utest.cpp b/test/utest.cpp
index 26e13ec..f695ee7 100644
--- a/test/utest.cpp
+++ b/test/utest.cpp
@@ -38,8 +38,8 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -69,8 +69,8 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -100,8 +100,8 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -144,10 +144,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -177,12 +179,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -212,12 +214,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -241,12 +243,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refDeAssert = {
- {"One", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
EXPECT_EQ(0, ledsAssert.size());
@@ -276,12 +278,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -305,12 +307,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refDeAssert = {
- {"One", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
EXPECT_EQ(0, ledsAssert.size());
@@ -352,16 +354,16 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
- {"Two", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -391,11 +393,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -419,11 +422,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -453,10 +457,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -480,9 +486,10 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -513,10 +520,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -541,9 +550,10 @@
// Need just the ledsAssserted populated with these.
// Does not action on [Three] since priority is [Blink]
std::set<Layout::LedAction> refAssert = {
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -567,9 +577,10 @@
// Need just the ledsDeAssserted populated with these.
std::set<Layout::LedAction> refDeAssert = {
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
EXPECT_EQ(0, ledsAssert.size());
@@ -601,10 +612,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -629,9 +642,10 @@
// Need just the ledsAssserted populated with these.
// [Three] does not get actioned since it has Blink priority
std::set<Layout::LedAction> refAssert = {
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -655,8 +669,10 @@
// Need just the ledsDeAssserted populated with these.
std::set<Layout::LedAction> refDeAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
@@ -669,8 +685,8 @@
// Need just the ledsAssert populated with these.
std::set<Layout::LedAction> refAssert = {
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
@@ -700,10 +716,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -728,11 +746,12 @@
// Need just the ledsAssserted populated with these.
// Three is set to ON due to ON priority.
std::set<Layout::LedAction> refAssert = {
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -756,8 +775,10 @@
// Need just the ledsDeAssserted populated with these.
// [Three] stays in [On] since [B] has it [On]
std::set<Layout::LedAction> refDeAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
EXPECT_EQ(0, ledsAssert.size());
@@ -788,10 +809,12 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -816,11 +839,12 @@
// Need just the ledsAssserted populated with these.
// Three is set to ON due to ON priority.
std::set<Layout::LedAction> refAssert = {
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -843,9 +867,10 @@
// Need just the ledsDeAssserted populated with these.
std::set<Layout::LedAction> refDeAssert = {
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
@@ -859,8 +884,8 @@
// Need just the ledsAssert populated with these.
// Since [Three] stood [On], need to go back to [Blink]
std::set<Layout::LedAction> refAssert = {
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
@@ -889,12 +914,14 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Seven", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Seven", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -918,7 +945,8 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -942,9 +970,10 @@
// Need just the ledsDeAssserted populated with these.
std::set<Layout::LedAction> refDeAssert = {
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Seven", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Seven", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
EXPECT_EQ(0, ledsAssert.size());
@@ -974,12 +1003,14 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1005,9 +1036,10 @@
// [Two] remains [On] due to higher priority.
// [Three] remains [Blink]
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1038,13 +1070,14 @@
// Need just the ledsAssserted populated with these.'Two' gets to Blink
// due to higher priority.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1070,10 +1103,12 @@
// [Three] remains [Blink] from previous
// [Two] moves to [On] from [Blink] due to [On] priority
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1106,13 +1141,14 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1138,10 +1174,12 @@
// [Two] turns [On] due to priority
// [Three] remains [Blink]
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1165,9 +1203,10 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refDeAssert = {
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
@@ -1181,8 +1220,8 @@
// Need just the ledsAssert populated with these.
// [Two] will go back to [Blink] from [On]
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
@@ -1205,13 +1244,14 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refDeAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
EXPECT_EQ(0, ledsAssert.size());
@@ -1257,15 +1297,16 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Ten", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Ten", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1292,10 +1333,12 @@
// [Three] remains on since it never was in [Blink] before
// [Ten] remains [Blink] due to priority: [Blink]
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1319,9 +1362,10 @@
// Need just the ledsDeAsssert populated with these.
std::set<Layout::LedAction> refDeAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
@@ -1330,8 +1374,8 @@
// [Three] remains [On] since it never changed state.
// [Two] remains [On] since it did not go back
std::set<Layout::LedAction> refAssert = {
- {"Ten", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"Ten", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
@@ -1365,15 +1409,16 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Ten", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Ten", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1400,10 +1445,12 @@
// [Three] remains on since it never was in [Blink] before
// [Ten] remains [Blink] due to priority: [Blink]
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1427,9 +1474,10 @@
// Need just the ledsDeAsssert populated with these.
std::set<Layout::LedAction> refDeAssert = {
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
@@ -1438,8 +1486,8 @@
// [Three] remains [On] since it never changed state.
// [Two] moves to [Blink] since there is no prior [On]
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
@@ -1472,14 +1520,16 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Ten", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Ten", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1506,11 +1556,12 @@
// [Three] remains on since it never was in [Blink] before
// [Ten] moves to [Blink] due to priority: [Blink]
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Ten", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Ten", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1545,14 +1596,16 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Ten", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Ten", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1579,11 +1632,12 @@
// [Three] remains on since it never was in [Blink] before
// [Ten] moves to [Blink] due to priority: [Blink]
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Ten", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Ten", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1608,9 +1662,10 @@
// Need just the ledsAssserted populated with these.
// [Ten] remains [Blink] due to priority.
std::set<Layout::LedAction> refDeAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
@@ -1619,8 +1674,8 @@
// [Three] remains [On] since it never was in [Blink] before
// [Ten] moves to [On] due to priority: [Blink]
std::set<Layout::LedAction> refAssert = {
- {"Ten", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"Ten", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
@@ -1653,14 +1708,16 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Ten", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
+ {"Two", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Ten", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1687,11 +1744,12 @@
// [Three] remains on since it never was in [Blink] before
// [Ten] moves to [Blink] due to priority: [Blink]
std::set<Layout::LedAction> refAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Ten", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Ten", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
EXPECT_EQ(0, ledsDeAssert.size());
@@ -1716,9 +1774,10 @@
// Need just the ledsAssserted populated with these.
// [Ten] remains [Blink] due to priority.
std::set<Layout::LedAction> refDeAssert = {
- {"Five", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Six", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
+ {"Five", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Six", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
@@ -1732,8 +1791,8 @@
// Need just the ledsAssert populated with these.
// [Two] will move to [Blink]
std::set<Layout::LedAction> refAssert = {
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
};
EXPECT_EQ(refAssert.size(), ledsAssert.size());
@@ -1756,15 +1815,16 @@
// Need just the ledsAssserted populated with these.
std::set<Layout::LedAction> refDeAssert = {
- {"One", phosphor::led::Layout::On, 0, 0, phosphor::led::Layout::On},
- {"Two", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::On},
- {"Three", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::Blink},
- {"Four", phosphor::led::Layout::On, 0, 0,
- phosphor::led::Layout::On},
- {"Ten", phosphor::led::Layout::Blink, 0, 0,
- phosphor::led::Layout::Blink},
+ {"One", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Two", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Three", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::Blink},
+ {"Four", phosphor::led::Layout::Action::On, 0, 0,
+ phosphor::led::Layout::Action::On},
+ {"Ten", phosphor::led::Layout::Action::Blink, 0, 0,
+ phosphor::led::Layout::Action::Blink},
};
EXPECT_EQ(refDeAssert.size(), ledsDeAssert.size());
EXPECT_EQ(0, ledsAssert.size());