Skip to content
Permalink
Browse files

Try and fix compatibility with Python 3.8.

  • Loading branch information
lamby committed Dec 5, 2019
1 parent d2f03ad commit 2eb4d52b02a4c34b85289fc0dc936da045704246
Showing with 4 additions and 4 deletions.
  1. +4 −4 tests/test_validation.py
@@ -14,8 +14,8 @@ def test_ok_result(self):
def test_msg_too_long_result(self):
# Arbitrarily chosen 'simple' error
backend = Backend()
with self.assertRaises(
MsgTooLong, expected_regexp=r"MsgTooLong: msg_too_long",
with self.assertRaisesRegex(
MsgTooLong, r"MsgTooLong: msg_too_long",
):
backend.validate(
'application/json',
@@ -25,9 +25,9 @@ def test_msg_too_long_result(self):

def test_channel_not_found_result(self):
backend = Backend()
with self.assertRaises(
with self.assertRaisesRegex(
ChannelNotFound,
expected_regexp=r"ChannelNotFound: channel 'bad-channel' could not be found",
r"ChannelNotFound: channel 'bad-channel' could not be found",
):
backend.validate(
'application/json',

0 comments on commit 2eb4d52

Please sign in to comment.
You can’t perform that action at this time.