- Timestamp:
- 05/03/2020 07:18:40 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/rest-api/rest-schema-sanitization.php
r47450 r47753 91 91 } 92 92 93 /** 94 * @ticket 50053 95 */ 96 public function test_format_uuid() { 97 $schema = array( 98 'type' => 'string', 99 'format' => 'uuid', 100 ); 101 $this->assertEquals( '44', rest_sanitize_value_from_schema( 44, $schema ) ); 102 $this->assertEquals( 'hello', rest_sanitize_value_from_schema( 'hello', $schema ) ); 103 $this->assertEquals( 104 '123e4567-e89b-12d3-a456-426655440000', 105 rest_sanitize_value_from_schema( '123e4567-e89b-12d3-a456-426655440000', $schema ) 106 ); 107 } 108 93 109 public function test_type_array() { 94 110 $schema = array(
Note: See TracChangeset
for help on using the changeset viewer.