diff options
author | Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com> | 2016-12-20 15:59:29 +0530 |
---|---|---|
committer | Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com> | 2017-01-17 21:48:42 +0530 |
commit | ed4907342897301ab96cbf2c617cafd78caf25a1 (patch) | |
tree | f91f21b7794892ca8d6d23b58a5d1ca0e97bb9d9 /led-main.cpp | |
parent | 98691fa88d107a1649847b032f1a9b1218061324 (diff) | |
download | phosphor-led-manager-ed4907342897301ab96cbf2c617cafd78caf25a1.tar.gz phosphor-led-manager-ed4907342897301ab96cbf2c617cafd78caf25a1.zip |
Enable gtest for testing LED set operations
This patchset enables gtest to allow different combinations
of LED set operations to be verified at build time.
Change-Id: I9c2ddf82c2e23be911233b23037ee44e3ce301db
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
Diffstat (limited to 'led-main.cpp')
-rw-r--r-- | led-main.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/led-main.cpp b/led-main.cpp index 8a091eb..2dc0dce 100644 --- a/led-main.cpp +++ b/led-main.cpp @@ -1,12 +1,14 @@ #include <iostream> +#include "ledlayout.hpp" #include "manager.hpp" #include "group.hpp" #include "config.h" +#include "led-gen.hpp" int main(void) { /** @brief Group manager object */ - phosphor::led::Manager manager; + phosphor::led::Manager manager(systemLedMap); /** @brief Dbus constructs used by LED Group manager */ sdbusplus::bus::bus bus = sdbusplus::bus::new_default(); @@ -18,7 +20,7 @@ int main(void) std::vector<std::unique_ptr<phosphor::led::Group>> groups; /** Now create so many dbus objects as there are groups */ - for (auto &grp: phosphor::led::Manager::ledMap) + for (auto &grp: systemLedMap) { groups.emplace_back(std::make_unique<phosphor::led::Group>( bus, grp.first, manager)); |