aboutsummaryrefslogtreecommitdiff
path: root/test/requests/main_web_functionality.py
diff options
context:
space:
mode:
authorBonfaceKilz2020-07-16 16:14:50 +0300
committerBonfaceKilz2020-07-16 16:24:22 +0300
commitd9bd69a8bd2e92d4aac078d936917929f2e5ca8e (patch)
treea28388be459218f813a371e1d386c97130d117df /test/requests/main_web_functionality.py
parentabce41e1408ad9e43328b133be9eeebc19b6802b (diff)
downloadgenenetwork2-d9bd69a8bd2e92d4aac078d936917929f2e5ca8e.tar.gz
Check for specific text in response and then assert a 200 code
"/show_trait?trait_id=1435395_s_at&dataset=HC_M2_0606_P" is missing in the response code. At one point the html structure changed.
Diffstat (limited to 'test/requests/main_web_functionality.py')
-rw-r--r--test/requests/main_web_functionality.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/requests/main_web_functionality.py b/test/requests/main_web_functionality.py
index 7b89b833..d070dab9 100644
--- a/test/requests/main_web_functionality.py
+++ b/test/requests/main_web_functionality.py
@@ -20,8 +20,9 @@ def check_search_page(host):
, search_terms_or=""
, search_terms_and="MEAN=(15 16) LRS=(23 46)")
result = requests.get(host+"/search", params=data)
- found = result.text.find("/show_trait?trait_id=1435395_s_at&dataset=HC_M2_0606_P")
+ found = result.text.find("records are shown below")
assert(found >= 0)
+ assert(result.status_code == 200)
print("OK")
check_traits_page(host, "/show_trait?trait_id=1435395_s_at&dataset=HC_M2_0606_P")