Adds external functions for validation.
This commit is contained in:
parent
6d541d38bc
commit
15d44c859e
11
apps/cic-ussd/tests/integration/ext/validator.py
Normal file
11
apps/cic-ussd/tests/integration/ext/validator.py
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
import logging
|
||||||
|
|
||||||
|
|
||||||
|
logg = logging.getLogger()
|
||||||
|
logg.setLevel(logging.DEBUG)
|
||||||
|
|
||||||
|
|
||||||
|
def validate_response(response, expected_response):
|
||||||
|
"""Makes sure that the response received matches the expected response"""
|
||||||
|
logg.debug(f'RESPONSE: {response.content.decode("utf-8")}')
|
||||||
|
assert response.content.decode('utf-8') == expected_response
|
Loading…
Reference in New Issue
Block a user