diff --git a/examples/placeholder/linux/include/MatterCallbacks.h b/examples/placeholder/linux/include/MatterCallbacks.h index b7a9c45de6dd76..210dd2b267ee72 100644 --- a/examples/placeholder/linux/include/MatterCallbacks.h +++ b/examples/placeholder/linux/include/MatterCallbacks.h @@ -39,6 +39,7 @@ TestCommand * GetTargetTest() if (test.get() == nullptr) { ChipLogError(chipTool, "Specified test command does not exist: %s", command); + PrintTestCommands(); return nullptr; } diff --git a/examples/placeholder/templates/tests-commands.zapt b/examples/placeholder/templates/tests-commands.zapt index f23545eebd8ac5..d2f60abee86a39 100644 --- a/examples/placeholder/templates/tests-commands.zapt +++ b/examples/placeholder/templates/tests-commands.zapt @@ -21,3 +21,17 @@ std::unique_ptrGetTestCommand(std::string testName) return nullptr; } + +void PrintTestCommands() +{ + {{#if (getTests)}} + {{#chip_tests (getTests)}} + {{#first}} + ChipLogError(chipTool, "Supported commands:"); + {{/first}} + ChipLogError(chipTool, "\t* {{filename}}"); + {{else}} + ChipLogError("\t No available commands."); + {{/chip_tests}} + {{/if}} +} diff --git a/zzz_generated/placeholder/app1/zap-generated/test/Commands.h b/zzz_generated/placeholder/app1/zap-generated/test/Commands.h index bab2de8270d0fa..a1b3008d43c825 100644 --- a/zzz_generated/placeholder/app1/zap-generated/test/Commands.h +++ b/zzz_generated/placeholder/app1/zap-generated/test/Commands.h @@ -395,3 +395,9 @@ std::unique_ptr GetTestCommand(std::string testName) return nullptr; } + +void PrintTestCommands() +{ + ChipLogError(chipTool, "Supported commands:"); + ChipLogError(chipTool, "\t* Test_TC_DM_1_3_Simulated"); +} diff --git a/zzz_generated/placeholder/app2/zap-generated/test/Commands.h b/zzz_generated/placeholder/app2/zap-generated/test/Commands.h index bab2de8270d0fa..a1b3008d43c825 100644 --- a/zzz_generated/placeholder/app2/zap-generated/test/Commands.h +++ b/zzz_generated/placeholder/app2/zap-generated/test/Commands.h @@ -395,3 +395,9 @@ std::unique_ptr GetTestCommand(std::string testName) return nullptr; } + +void PrintTestCommands() +{ + ChipLogError(chipTool, "Supported commands:"); + ChipLogError(chipTool, "\t* Test_TC_DM_1_3_Simulated"); +} diff --git a/zzz_generated/placeholder/zap-generated/af-gen-event.h b/zzz_generated/placeholder/zap-generated/af-gen-event.h new file mode 100644 index 00000000000000..e69de29bb2d1d6