test_php_application.py (1029:687f7cc7aae2) test_php_application.py (1064:75a64629661f)
1import re
2import unittest
3from unit.applications.lang.php import TestApplicationPHP
4
5class TestPHPApplication(TestApplicationPHP):
6 prerequisites = ['php']
7
8 def before_disable_functions(self):

--- 70 unchanged lines hidden (view full) ---

79
80 resp = self.get(url='/?')
81
82 self.assertEqual(resp['status'], 200, 'query string empty status')
83 self.assertEqual(
84 resp['headers']['Query-String'], '', 'query string empty'
85 )
86
1import re
2import unittest
3from unit.applications.lang.php import TestApplicationPHP
4
5class TestPHPApplication(TestApplicationPHP):
6 prerequisites = ['php']
7
8 def before_disable_functions(self):

--- 70 unchanged lines hidden (view full) ---

79
80 resp = self.get(url='/?')
81
82 self.assertEqual(resp['status'], 200, 'query string empty status')
83 self.assertEqual(
84 resp['headers']['Query-String'], '', 'query string empty'
85 )
86
87 @unittest.expectedFailure
88 def test_php_application_query_string_absent(self):
89 self.load('query_string')
90
91 resp = self.get()
92
93 self.assertEqual(resp['status'], 200, 'query string absent status')
94 self.assertEqual(
95 resp['headers']['Query-String'], '', 'query string absent'

--- 106 unchanged lines hidden (view full) ---

202 self.get()['headers']['X-File'],
203 self.current_dir + '/php/ini_precision/ini/php.ini',
204 'ini file',
205 )
206 self.assertEqual(
207 self.get()['headers']['X-Precision'], '4', 'ini value'
208 )
209
87 def test_php_application_query_string_absent(self):
88 self.load('query_string')
89
90 resp = self.get()
91
92 self.assertEqual(resp['status'], 200, 'query string absent status')
93 self.assertEqual(
94 resp['headers']['Query-String'], '', 'query string absent'

--- 106 unchanged lines hidden (view full) ---

201 self.get()['headers']['X-File'],
202 self.current_dir + '/php/ini_precision/ini/php.ini',
203 'ini file',
204 )
205 self.assertEqual(
206 self.get()['headers']['X-Precision'], '4', 'ini value'
207 )
208
210 @unittest.expectedFailure
209 @unittest.skip('not yet')
211 def test_php_application_ini_admin_user(self):
212 self.load('ini_precision')
213
214 self.assertIn(
215 'error',
216 self.conf(
217 {"user": {"precision": "4"}, "admin": {"precision": "5"}},
218 'applications/ini_precision/options',

--- 208 unchanged lines hidden ---
210 def test_php_application_ini_admin_user(self):
211 self.load('ini_precision')
212
213 self.assertIn(
214 'error',
215 self.conf(
216 {"user": {"precision": "4"}, "admin": {"precision": "5"}},
217 'applications/ini_precision/options',

--- 208 unchanged lines hidden ---