WordPress.org

Make WordPress Core

Ticket #30284: 10823-remove.diff

File 10823-remove.diff, 2.3 KB (added by MikeHansenMe, 5 years ago)

#10823

  • tests/phpunit/tests/formatting/SanitizeTitleWithDashes.php

    diff --git a/tests/phpunit/tests/formatting/SanitizeTitleWithDashes.php b/tests/phpunit/tests/formatting/SanitizeTitleWithDashes.php
    index 53931bd..1b9d5d7 100644
    a b class Tests_Formatting_SanitizeTitleWithDashes extends WP_UnitTestCase { 
    3535                $this->assertEquals("penn-teller-bull", sanitize_title_with_dashes("penn & teller bull"));
    3636        }
    3737
    38         /**
    39          * @ticket 10823
    40          */
    41         function test_strips_entities() {
    42                 $this->assertEquals("no-entities-here", sanitize_title_with_dashes("No   Entities – Here &"));
    43                 $this->assertEquals("one-two", sanitize_title_with_dashes("One & Two", '', 'save'));
    44                 $this->assertEquals("one-two", sanitize_title_with_dashes("One { Two;", '', 'save'));
    45                 $this->assertEquals("one-two", sanitize_title_with_dashes("One & Two;", '', 'save'));
    46                 $this->assertEquals("one-two", sanitize_title_with_dashes("One Two™;", '', 'save'));
    47                 $this->assertEquals("one-two", sanitize_title_with_dashes("One && Two;", '', 'save'));
    48                 $this->assertEquals("onetwo", sanitize_title_with_dashes("One&Two", '', 'save'));
    49                 $this->assertEquals("onetwo-test", sanitize_title_with_dashes("One&Two Test;", '', 'save'));
    50         }
    51 
    5238        function test_replaces_nbsp() {
    5339                $this->assertEquals("dont-break-the-space", sanitize_title_with_dashes("don't break the space", '', 'save'));
    5440        }
  • tests/phpunit/tests/formatting/SanitizeUser.php

    diff --git a/tests/phpunit/tests/formatting/SanitizeUser.php b/tests/phpunit/tests/formatting/SanitizeUser.php
    index 3f7f03b..02ca762 100644
    a b class Tests_Formatting_SanitizeUser extends WP_UnitTestCase { 
    99                $expected = is_multisite() ? 'captain awesome' : 'Captain Awesome';
    1010                $this->assertEquals($expected, sanitize_user($input));
    1111        }
    12         /**
    13          * @ticket 10823
    14          */
    15         function test_strips_entities() {
    16                 $this->assertEquals("ATT", sanitize_user("AT&T"));
    17                 $this->assertEquals("ATT Test;", sanitize_user("AT&T Test;"));
    18                 $this->assertEquals("AT&T Test;", sanitize_user("AT&T Test;"));
    19         }
     12
    2013        function test_strips_percent_encoded_octets() {
    2114                $expected = is_multisite() ? 'franois' : 'Franois';
    2215                $this->assertEquals( $expected, sanitize_user( "Fran%c3%a7ois" ) );