diff options
author | imarom <imarom@cisco.com> | 2015-12-08 07:43:24 -0500 |
---|---|---|
committer | imarom <imarom@cisco.com> | 2015-12-08 07:50:32 -0500 |
commit | feb152b7d5eb531d439a4950d27cbc44031daf92 (patch) | |
tree | 963cadc7ee2646a1004bd1213c1d398e9b24be36 /scripts/automation/trex_control_plane/client | |
parent | d2cd7b153eef887cbf76ada54149e67bc1057d1e (diff) |
text based TUI (does not use ncurses)
Diffstat (limited to 'scripts/automation/trex_control_plane/client')
-rwxr-xr-x | scripts/automation/trex_control_plane/client/trex_stateless_client.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/scripts/automation/trex_control_plane/client/trex_stateless_client.py b/scripts/automation/trex_control_plane/client/trex_stateless_client.py index 0c6d9855..0a583f46 100755 --- a/scripts/automation/trex_control_plane/client/trex_stateless_client.py +++ b/scripts/automation/trex_control_plane/client/trex_stateless_client.py @@ -321,6 +321,8 @@ class Port(object): self.streams[stream_id] = None + self.state = self.STATE_STREAMS if len(self.streams > 0) else self.STATE_IDLE + return self.ok() # remove all the streams @@ -335,6 +337,8 @@ class Port(object): self.streams = {} + self.state = self.STATE_IDLE + return self.ok() # get a specific stream @@ -1364,12 +1368,13 @@ class CTRexStatelessClient(object): # set to show all stats if no filter was given mask = trex_stats.ALL_STATS_OPTS - # get stats objects, as dictionary stats = self.cmd_stats(opts.ports, mask) + # print stats to screen for stat_type, stat_data in stats.iteritems(): text_tables.print_table_with_header(stat_data.text_table, stat_type) + return RC_OK() @@ -1481,6 +1486,7 @@ class CTRexStatelessClient(object): def _filter_namespace_args(namespace, ok_values): return {k: v for k, v in namespace.__dict__.items() if k in ok_values} + ################################# # ------ private classes ------ # class CCommLink(object): |