aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit/cli
diff options
context:
space:
mode:
Diffstat (limited to 'tests/unit/cli')
-rw-r--r--tests/unit/cli/cmd_qpi_test.py24
1 files changed, 7 insertions, 17 deletions
diff --git a/tests/unit/cli/cmd_qpi_test.py b/tests/unit/cli/cmd_qpi_test.py
index e7823c9b..ba5f814e 100644
--- a/tests/unit/cli/cmd_qpi_test.py
+++ b/tests/unit/cli/cmd_qpi_test.py
@@ -20,24 +20,14 @@ def runner():
def test_list(runner):
result = runner.invoke(cli, ['qpi', 'list'])
- assert 'QPIs' and 'compute' in result.output
-
-
-def test_run(runner):
- result = runner.invoke(cli, ['qpi', 'run', 'fake-qpi'])
- assert result.output == ''
-
- result = runner.invoke(cli, ['qpi', 'run'])
- assert 'Missing argument "name".' in result.output
+ assert 'QPI' in result.output
+ assert 'compute' in result.output
+ assert 'Description' in result.output
+ assert 'QTIP Performance Index of compute' in result.output
def test_show(runner):
result = runner.invoke(cli, ['qpi', 'show', 'compute'])
- assert 'Name: compute' in result.output
- assert 'Description: sample performance index of computing' in result.output
-
- result = runner.invoke(cli, ['qpi', 'show'])
- assert 'Missing argument "name".' in result.output
-
- result = runner.invoke(cli, ['qpi', 'show', 'xyz'])
- assert "ERROR: qpi spec: xyz not found" in result.output
+ assert 'QPI' in result.output
+ assert 'Description' in result.output
+ assert 'Formula' in result.output