mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2026-11-25 13:11:36 +00:00
test(device): add tests for the runner options and interactive keys
- --print-options prints the computed options and does not start the device - --print-channels and --version do not start the device - Interactive control: h, c, p, k and an invalid key print their action - Register two channel endpoints in the StateAction device - Add disabled tests for known defects: --print-channels and --version print nothing (console severity "nolog"); keys that arrive in one read stay in the std::cin buffer and are never handled Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -41,6 +41,13 @@ class StateAction : public Device
|
||||
void ResetTask() override { ActIfRequested("ResetTask"); }
|
||||
void Reset() override { ActIfRequested("Reset"); }
|
||||
|
||||
// For the --print-channels test.
|
||||
void RegisterChannelEndpoints() override
|
||||
{
|
||||
RegisterChannelEndpoint("data");
|
||||
RegisterChannelEndpoint("fan", 2, 4);
|
||||
}
|
||||
|
||||
private:
|
||||
void ActIfRequested(std::string_view state)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user