comparison test/test_liveserver.py @ 6568:59eebe55ca1d

Mark last two test works in progress. Getting failures in CI. Under python3, it's because I am using a hard coded url that fails because there is another file being created before it. Under python2, looks like rest upload is crashing in cgi.py calling readline(1<<16). Apparently the readline being triggered there doesn't support an additional (buffersize???) parameter Maybe wsgi.input's readline.
author John Rouillard <rouilj@ieee.org>
date Tue, 21 Dec 2021 02:07:29 -0500
parents 34199d2fef48
children 3ae0c0fb2d08
comparison
equal deleted inserted replaced
6567:34199d2fef48 6568:59eebe55ca1d
889 print(f.headers) 889 print(f.headers)
890 890
891 self.assertEqual(f.status_code, 200) 891 self.assertEqual(f.status_code, 200)
892 self.assertEqual(f.headers['Cache-Control'], 'public, max-age=1209600') 892 self.assertEqual(f.headers['Cache-Control'], 'public, max-age=1209600')
893 893
894 @pytest.mark.xfail(reason="Work in progress")
894 def test_new_issue_with_file_upload(self): 895 def test_new_issue_with_file_upload(self):
895 # Set up session to manage cookies <insert blue monster here> 896 # Set up session to manage cookies <insert blue monster here>
896 session = requests.Session() 897 session = requests.Session()
897 898
898 # login using form 899 # login using form
916 # download file and verify content 917 # download file and verify content
917 f = session.get(self.url_base()+'/file1/text1.txt') 918 f = session.get(self.url_base()+'/file1/text1.txt')
918 self.assertEqual(f.text, file_content) 919 self.assertEqual(f.text, file_content)
919 print(f.text) 920 print(f.text)
920 921
921 922 @pytest.mark.xfail(reason="Work in progress")
922 def test_new_file_via_rest(self): 923 def test_new_file_via_rest(self):
923 924
924 session = requests.Session() 925 session = requests.Session()
925 session.auth = ('admin', 'sekrit') 926 session.auth = ('admin', 'sekrit')
926 927

Roundup Issue Tracker: http://roundup-tracker.org/