Skip to content

Commit

Permalink
Coverage enhancer
Browse files Browse the repository at this point in the history
  • Loading branch information
mators11 committed Jan 22, 2014
1 parent dc67ba2 commit 89f362e
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion tests/TestCli.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,15 @@ def test_connect_disconnect():
eq_(cshell.do_connect('cryptoim1'), False)
eq_(cshell.do_disconnect(''), True)
eq_(cshell.do_disconnect(''), False)
eq_(cshell.do_connect('cryptoim1@jabber.de crypto_test'), True)
eq_(cshell.do_disconnect(''), True)
eq_(cshell.do_disconnect(''), False)

def test_send():

cshell = CryptoShell('main.cfg')
cshell.test_mode = True
eq_(cshell.do_send('message before connection'), False)
eq_(cshell.do_connect('cryptoim2'), True)
TestXMPP.waitForSession(cshell.xmpp_client, True)
eq_(cshell.do_send(''), False)
Expand Down Expand Up @@ -64,7 +68,7 @@ def test_chat_stopchat_exit():

exit_code = -1
try:
cshell.do_exit('')
cshell.do_q('')
except SystemExit:
exit_code = 0
eq_(0, exit_code)
Expand All @@ -79,6 +83,7 @@ def test_addfriend_removefriend():
eq_(cshell.do_addfriend('testfriend testfriend@jabber.de'), False)
eq_(cshell.do_addfriend(''), False)
eq_(cshell.do_removefriend('testfriend'), True)
eq_(cshell.do_removefriend('testfriend another few lines'), False)
eq_(cshell.do_removefriend(''), False)
eq_(cshell.do_removefriend('testfriend'), False)

Expand Down

0 comments on commit 89f362e

Please sign in to comment.