modality sut

Command: modality sut

List, add, inspect, or remove Systems Under Test (SUTs) and their constituent entities. Can set a default SUT. This command's functionality is exposed via subcommands:

# modality sut component

Command: modality sut component

List and inspect component definitions for the given SUT. Subcommands:

# modality sut component inspect

Command: modality sut component inspect <component name | id>

Print the definition of the given component.

# Options

<component name | id> - Identifier for the component. Component ID can be found with modality sut component list -vv.

--color <auto | always | never> - Whether to color the output. Default is auto, which will autodetect the target output location and whether or not it is capable of handling color escape codes.

-f, --format - The printed output format. Defaults to text.

--include-internal - Include Modality's internal entities.

--using <sut name> - Use the given SUT rather than the default one.

# modality sut component inspect Example

$ modality sut component inspect monitor-component
Name: monitor-component
ID: 35a90f7f-25c6-404e-a5df-ec3d51268723
Tags: []
SUT: example-sut
Probes:
  MONITOR_PROBE
Events:
  INIT
  DEINIT
  RECVD_HEARTBEAT_MSG
  HEARTBEAT_SENDER_ID_CHECK
  PRODUCER_HEARTBEAT_TIMEOUT
  CONSUMER_HEARTBEAT_TIMEOUT
Mutators:
...

# modality sut component list

Command: modality sut component list

List components in the SUT.

# Options

--color <auto | always | never> - Whether to color the output. Default is auto, which will autodetect the target output location and whether or not it is capable of handling color escape codes.

--include-internal - Include Modality's internal components.

--using <sut name> - Use the given SUT rather than the default one.

-v, -vv, --verbose - Provide (more) verbose output (-v, -vv).

# modality sut component list Example

$ modality sut component list
NAME                TAGS  PROBES  EVENTS
consumer-component  []    1       5
monitor-component   []    1       6
producer-component  []    1       5

# modality sut create

Command: modality sut create <sut definition path>

Add a new SUT by giving Modality a path to a directory containing a SUT Definition: a SUT.toml file and component directories.

# Options

<sut definition path> - Path to a directory containing a SUT.toml file and component directories.

# modality sut create Example

$ modality sut create .

# modality sut delete

Command: modality sut delete <sut name>

Remove the given SUT.

# Options

<sut name> - Name of the SUT to delete.

--force - Bypass the user input confirmation check.

# modality sut delete Example

$ modality sut delete test-sut

# modality sut event

Command: modality sut event

List and inspect event definitions for the given SUT. Subcommands:

# modality sut event inspect

Command: modality sut event inspect

Print the definition of the given event.

# Options

<name | id> - Identifier for the event. Event ID can be found with modality sut event list -v.

--color <auto | always | never> - Whether to color the output. Default is auto, which will autodetect the target output location and whether or not it is capable of handling color escape codes.

-f, --format - The printed output format. Defaults to text.

--include-internal - Include Modality's internal entities in the output.

--using <sut name> - Use the given SUT rather than the default one.

# modality sut event inspect Example

$ modality sut event inspect MEASUREMENT_SAMPLED
Name: MEASUREMENT_SAMPLED
Description: Producer sampled raw measurement
ID: 3
Type Hint: I8
Kind: event
Component: producer-component
Source: c-example/src/producer/main.c#L128
Tags: [measurement, producer]

# modality sut event list

Command: modality sut event list

List events in the SUT.

# Options

--color <auto | always | never> - Whether to color the output. Default is auto, which will autodetect the target output location and whether or not it is capable of handling color escape codes.

--include-internal - Include Modality's internal events.

--using <sut name> - Use the given SUT rather than the default one.

-v, -vv, -vvv, --verbose - Provide (more) verbose output (-v, -vv, -vvv).

# modality sut event list Example

$ modality sut event list
NAME                        TAGS
CONSUMER_HEARTBEAT_TIMEOUT  [heartbeat, monitor, timeout]
DEINIT                      [monitor]
DEINIT                      [consumer]
DEINIT                      [producer]
HEARTBEAT_SENDER_ID_CHECK   [heartbeat, monitor]
INIT                        [monitor]
INIT                        [consumer]
INIT                        [producer]
MEASUREMENT_SAMPLED         [measurement, producer]
MEASUREMENT_SAMPLE_CHECK    [consumer, measurement]
PRODUCER_HEARTBEAT_TIMEOUT  [heartbeat, monitor, timeout]
RECVD_HEARTBEAT_MSG         [heartbeat, monitor]
RECVD_MEASUREMENT_MSG       [consumer, measurement]
SENT_HEARTBEAT_MSG          [consumer, heartbeat]
SENT_HEARTBEAT_MSG          [heartbeat, producer]
SENT_MEASUREMENT_MSG        [measurement, producer]

# modality sut inspect

Command:: modality sut inspect <sut name>

Print detailed information and metadata about the given SUT.

# Options

<sut name> - Name of the SUT to inspect.

--color <auto | always | never> - Whether to color the output. Default is auto, which will autodetect the target output location and whether or not it is capable of handling color escape codes.

-f, --format - The printed output format. Defaults to text.

--include-internal - Include Modality's internal events, probes, and/or components.

# modality sut inspect Example

$ modality sut inspect example-sut
Name: example-sut
Created at: 2021-05-11 09:57:04 UTC
Created by: example-user
Components:
  consumer-component
  producer-component
  monitor-component
Probes:
  CONSUMER_PROBE
  MONITOR_PROBE
  PRODUCER_PROBE
Events:
  INIT
  DEINIT
  RECVD_HEARTBEAT_MSG
  HEARTBEAT_SENDER_ID_CHECK
  PRODUCER_HEARTBEAT_TIMEOUT
  CONSUMER_HEARTBEAT_TIMEOUT
  INIT
  DEINIT
  RECVD_MEASUREMENT_MSG
  MEASUREMENT_SAMPLE_CHECK
  SENT_HEARTBEAT_MSG
  INIT
  DEINIT
  MEASUREMENT_SAMPLED
  SENT_MEASUREMENT_MSG
  SENT_HEARTBEAT_MSG
Mutators:
  heartbeat-delay-mutator
  sample-data-mutator

# modality sut list

Command: modality sut list

List all known SUTs.

# Options

--color <auto | always | never> - Whether to color the output. Default is auto, which will autodetect the target output location and whether or not it is capable of handling color escape codes.

-v, --verbose - Provide verbose output.

# modality sut list Example

$ modality sut list
NAME      COMPONENTS  SESSIONS
drone     7           1
test-sut  2           2

$ modality sut list -v
NAME      COMPONENTS  SESSIONS  CREATED AT               CREATED BY
drone     7           1         2021-03-30 14:07:39 UTC  
test-sut  2           2         2021-04-05 04:45:44 UTC  test-user

# modality sut mutator

Command: modality sut mutator

List and inspect mutator definitions for the given SUT. Subcommands:

# modality sut mutator inspect

Command: modality sut mutator inspect <mutator name | id>

Print the definition of the given mutator.

# Options

<mutator name | id> - Identifier for the mutator. Mutator ID can be found with modality sut mutator list -vv.

--color <auto | always | never> - Whether to color the output. Default is auto, which will autodetect the target output location and whether or not it is capable of handling color escape codes.

-f, --format - The printed output format. Defaults to text.

--include-internal - Include Modality's internal entities in the output.

--using <sut name> - Use the given SUT rather than the default one.

# modality sut mutator inspect Example

$ modality sut mutator inspect sample-data-mutator
Name: sample-data-mutator
ID Hash: 11820918689057293432
Source: src/producer/main.c#L138
Tags: [producer, measurement]
Probes:
  PRODUCER_PROBE
Parameters:
  Name: sample
    Type: i8
    Minimum Effect Value: 0
    Nominal: [-50..50]
    Safety: [-100..100]
    Hard: [-128..127]

# modality sut mutator list

Command: modality sut mutator list

List mutators in the SUT.

# Options

--color <auto | always | never> - Whether to color the output. Default is auto, which will autodetect the target output location and whether or not it is capable of handling color escape codes.

--include-internal - Include Modality's internal entities in the output.

--using <sut name> - Use the given SUT rather than the default one.

-v, -vv, --verbose - Provide (more) verbose output (-v, -vv).

# modality sut mutator list Example

$ modality sut mutator list
NAME                     TAGS
heartbeat-delay-mutator  [consumer, heartbeat]
sample-data-mutator      [measurement, producer]

# modality sut probe

Command: modality sut probe

List and inspect probe definitions for the given SUT. Subcommands:

# modality sut probe inspect

Command: modality sut probe inspect <probe name | id>

Print the definition of the given probe.

# Options

<probe name | id> - Identifier for the probe. Probe ID can be found with modality sut probe list -v.

--color <auto | always | never> - Whether to color the output. Default is auto, which will autodetect the target output location and whether or not it is capable of handling color escape codes.

-f, --format - The printed output format. Defaults to text.

--include-internal - Include Modality's internal entities.

--using <sut name> - Use the given SUT rather than the default one.

# modality sut probe inspect Example

$ modality sut probe inspect CONSUMER_PROBE
Name: CONSUMER_PROBE
Description: Consumer probe
ID: 438896705
Component: consumer-component
Source: c-example/src/consumer/main.c#L65
Tags: [c-example, consumer]

# modality sut probe list

Command: modality sut probe list

List probes in the SUT.

# Options

--color <auto | always | never> - Whether to color the output. Default is auto, which will autodetect the target output location and whether or not it is capable of handling color escape codes.

--include-internal - Include Modality's internal probes.

--using <sut name> - Use the given SUT rather than the default one.

-v, -vv, --verbose - Provide (more) verbose output (-v, -vv).

# modality sut probe list Example

$ modality sut probe list
NAME            TAGS
CONSUMER_PROBE  [c-example, consumer]
MONITOR_PROBE   [c-example, monitor]
PRODUCER_PROBE  [c-example, producer]

# modality sut use

Command: modality sut use <sut name>

Set the default SUT.

# Options

<sut name> - Name of the SUT to use as default.

--force - Use the given name as the default SUT even if it doesn't currently exist.

# modality sut use Example

$ modality sut use example-session