From d9bd69a8bd2e92d4aac078d936917929f2e5ca8e Mon Sep 17 00:00:00 2001 From: BonfaceKilz Date: Thu, 16 Jul 2020 16:14:50 +0300 Subject: 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. --- test/requests/main_web_functionality.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'test/requests') 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") -- cgit v1.2.3