aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTrygve Aaberge <trygveaa@gmail.com>2017-10-08 23:51:15 +0200
committerTrygve Aaberge <trygveaa@gmail.com>2017-10-08 23:58:49 +0200
commitb8d4a3375d105a22aa3d90a199ecf9a8ff16e5b6 (patch)
tree2923bf6ad72a77d3fd6f3b993a4e4aed815bc535
parente64293b41573b5caad2ebf343d9a4397cef22a67 (diff)
downloadwee-slack-b8d4a3375d105a22aa3d90a199ecf9a8ff16e5b6.tar.gz
test: Map all weechat return codes in tests
So we can assert on all of the return values. Since True == 1 in python, this doesn't change the value of WEECHAT_RC_OK.
-rw-r--r--_pytest/conftest.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/_pytest/conftest.py b/_pytest/conftest.py
index 232814f..ca267fd 100644
--- a/_pytest/conftest.py
+++ b/_pytest/conftest.py
@@ -49,7 +49,9 @@ class FakeWeechat():
this is the thing that acts as "w." everywhere..
basically mock out all of the weechat calls here i guess
"""
- WEECHAT_RC_OK = True
+ WEECHAT_RC_ERROR = 0
+ WEECHAT_RC_OK = 1
+ WEECHAT_RC_OK_EAT = 2
def __init__(self):
pass