Changeset 31310
- Timestamp:
- 01/31/2015 02:01:46 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/functions.php
r31052 r31310 14 14 $this->assertEquals(array(), wp_parse_args($y)); 15 15 } 16 16 17 function test_wp_parse_args_array() { 17 18 // arrays … … 21 22 $this->assertEquals(array('_baba' => 5, 'yZ' => 'baba', 'a' => array(5, 111, 'x')), wp_parse_args($b)); 22 23 } 24 23 25 function test_wp_parse_args_defaults() { 24 26 $x = new MockClass; … … 31 33 $this->assertEquals(array('_baba' => 5, 'yZ' => 'baba', 'a' => array(5, 111, 'x')), wp_parse_args($x, $e)); 32 34 } 35 33 36 function test_wp_parse_args_other() { 34 37 $b = true; … … 39 42 $this->assertEquals($ss, wp_parse_args($q)); 40 43 } 44 45 /** 46 * @ticket 30753 47 */ 48 function test_wp_parse_args_boolean_strings() { 49 $args = wp_parse_args( 'foo=false&bar=true', array() ); 50 $this->assertInternalType( 'string', $args['foo'] ); 51 $this->assertInternalType( 'string', $args['bar'] ); 52 } 53 41 54 function test_size_format() { 42 55 $b = 1;
Note: See TracChangeset
for help on using the changeset viewer.