Skip to content

Assert output is empty #297

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 2 commits into from
Jul 22, 2019
Merged

Assert output is empty #297

merged 2 commits into from
Jul 22, 2019

Conversation

masci
Copy link
Contributor

@masci masci commented Jul 22, 2019

Following up discussion at #96 we ensure that when command has no output nothing will be printed out, even if the selected format was JSON (docker cli style).

Copy link
Contributor

@rsora rsora left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@@ -33,11 +33,14 @@ def test_command_help():


def test_command_lib_list():
"""
When ouput is empty, nothing is printed out, no matter the output format
"""
result = run_command('lib list')
assert result.ok
assert result.stderr == ''
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also change this to

assert '' == result.stderr

to keep the style consistent

@masci masci merged commit 620a4c1 into master Jul 22, 2019
@masci masci deleted the massi/lib-list branch July 22, 2019 14:50
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants