Skip to content

Commit

Permalink
Restyled by whitespace
Browse files Browse the repository at this point in the history
  • Loading branch information
restyled-commits authored and du48s03 committed Oct 29, 2021
1 parent dda0d20 commit 43be5a4
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions src/app/clusters/mode-select-server/mode-select-server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ CHIP_ERROR ModeSelectAttrAccess::Read(const ConcreteAttributePath & aPath, Attri
{
VerifyOrDie(aPath.mClusterId == ModeSelect::Id);

const ModeSelect::StaticSupportedModesManager & gSupportedModeManager =
const ModeSelect::StaticSupportedModesManager & gSupportedModeManager =
ModeSelect::StaticSupportedModesManager::getStaticSupportedModesManagerInstance();

if (ModeSelect::Attributes::SupportedModes::Id == aPath.mAttributeId)
Expand Down Expand Up @@ -91,7 +91,7 @@ bool emberAfModeSelectClusterChangeToModeCallback(
uint8_t newMode = commandData.newMode;
// Check that the newMode matches one of the supported options
const ModeSelect::Structs::ModeOptionStruct::Type * modeOptionPtr;
const ModeSelect::StaticSupportedModesManager & gSupportedModeManager =
const ModeSelect::StaticSupportedModesManager & gSupportedModeManager =
ModeSelect::StaticSupportedModesManager::getStaticSupportedModesManagerInstance();
EmberAfStatus checkSupportedModeStatus = gSupportedModeManager.getModeOptionByMode(endpointId, newMode, &modeOptionPtr);
if (EMBER_ZCL_STATUS_SUCCESS != checkSupportedModeStatus)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ class StaticSupportedModesManager : public chip::app::Clusters::ModeSelect::Supp
base_iterator_type& operator++() override { ++mPtr; return *this; }

bool operator== (const base_iterator_type& other) const override
{
{
// Warning: we are not doing type check
// TODO: use of typeid requires -frtti
// if (typeid(other) != typeid(*this))
Expand Down
4 changes: 2 additions & 2 deletions src/app/clusters/mode-select-server/supported-modes-manager.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,12 @@ class SupportedModesManager
};

/**
* A factory that can return the ModeOptionStructIterators for a specific endpoint.
* A factory that can return the ModeOptionStructIterators for a specific endpoint.
*/
struct ModeOptionStructIteratorFactory
{
using const_pointer = const ModeOptionStructIterator*;

/**
* Returns the ModeOptionStructIterator to the first option.
*/
Expand Down
8 changes: 4 additions & 4 deletions src/app/tests/suites/TestModeSelectCluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ name: Mode Select Cluster Tests

config:
cluster: "Mode Select"
endpoint: 1
endpoint: 1

tests:
- label: "Read CurrentMode"
Expand Down Expand Up @@ -56,7 +56,7 @@ tests:
- type: list
- minLength: 3
- maxLength: 3

- label: "Change to Supported Mode"
command: "changeToMode"
arguments:
Expand All @@ -70,7 +70,7 @@ tests:
command: "readAttribute"
attribute: "CurrentMode"
response:
value: 4
value: 4

- label: "Change to Unsupported Mode"
command: "changeToMode"
Expand All @@ -79,4 +79,4 @@ tests:
- name: "NewMode"
value: 2
response:
error: 1
error: 1

0 comments on commit 43be5a4

Please sign in to comment.