diff options
author | Andrey Andreev <narf@devilix.net> | 2021-09-14 12:47:31 +0200 |
---|---|---|
committer | Andrey Andreev <narf@devilix.net> | 2021-09-14 12:48:54 +0200 |
commit | 87928371de8a316c9880a451fae04d9785c32840 (patch) | |
tree | 105f60457936882e1d41fcf03c4e7189929951f3 /tests/codeigniter/core | |
parent | 063aee9e0f6f560b479958e4fae9f5b77048c8fa (diff) |
Merge pull request #6045 from gxgpet/develop_fixtravis
Fixes Travis pipeline. Adding PHPUnit 8.
Diffstat (limited to 'tests/codeigniter/core')
-rw-r--r-- | tests/codeigniter/core/Input_test.php | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/tests/codeigniter/core/Input_test.php b/tests/codeigniter/core/Input_test.php index 976941d41..3cce00414 100644 --- a/tests/codeigniter/core/Input_test.php +++ b/tests/codeigniter/core/Input_test.php @@ -22,6 +22,14 @@ class Input_test extends CI_TestCase { // -------------------------------------------------------------------- + public function tear_down() + { + $_POST = []; + $_GET = []; + } + + // -------------------------------------------------------------------- + public function test_get_not_exists() { $this->assertSame(array(), $this->input->get()); @@ -136,7 +144,7 @@ class Input_test extends CI_TestCase { $this->assertEquals("Hello, i try to [removed]alert('Hack');[removed] your site", $harmless); $_SERVER['REQUEST_METHOD'] = 'POST'; - $_POST['foo']['bar'] = 'baz'; + $_POST['foo'] = array('bar' => 'baz'); $barArray = array('bar' => 'baz'); $this->assertEquals('baz', $this->input->post('foo[bar]')); |