diff options
author | Todd Leonhardt <todd.leonhardt@gmail.com> | 2017-06-25 15:59:12 -0400 |
---|---|---|
committer | Todd Leonhardt <todd.leonhardt@gmail.com> | 2017-06-25 15:59:12 -0400 |
commit | b44ffe7d637d513be5be916f867b29272470c9bd (patch) | |
tree | a9c304d8b36bffc6b402bfaea54a8f5cff01a3e3 /tests/test_cmd2.py | |
parent | 19db0f3ccdbe62b181ed61f127e13f2412762bee (diff) | |
download | cmd2-git-b44ffe7d637d513be5be916f867b29272470c9bd.tar.gz |
Skip the pastebuffer_read_and_write test if tools for interacting with clipboard/pastebuffer are not available
Diffstat (limited to 'tests/test_cmd2.py')
-rw-r--r-- | tests/test_cmd2.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/tests/test_cmd2.py b/tests/test_cmd2.py index b453bca9..4fd9ca1c 100644 --- a/tests/test_cmd2.py +++ b/tests/test_cmd2.py @@ -647,11 +647,10 @@ def test_cmdloop_without_rawinput(): assert out == expected +@pytest.mark.skipif(not cmd2.can_clip, + reason="CLI utility for interacting with PasteBuffer/ClipBoard is not available") def test_pastebuffer_read_and_write(): text_to_pb = 'This is a test ...' cmd2.write_to_paste_buffer(text_to_pb) text_from_pb = cmd2.get_paste_buffer() - - # If the tools for interacting with the clipboard/pastebuffer are available - if cmd2.can_clip: - assert text_from_pb == text_to_pb + assert text_from_pb == text_to_pb |