Make WordPress Core


Ignore:
Timestamp:
10/29/2019 02:26:41 PM (5 years ago)
Author:
SergeyBiryukov
Message:

Build/Test Tools: Ignore EOL differences in tests using multiline string assertions.

Unix vs. Windows EOL style mismatches can cause misleading failures in tests using the heredoc syntax (<<<) or multiline strings as the expected result.

Fixes #31432. See #42594, #47411.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/general/paginateLinks.php

    r46586 r46612  
    2626
    2727        $links = paginate_links( array( 'total' => 50 ) );
    28         $this->assertEquals( $expected, $links );
     28        $this->assertEqualsIgnoreEOL( $expected, $links );
    2929    }
    3030
     
    4949            )
    5050        );
    51         $this->assertEquals( $expected, $links );
     51        $this->assertEqualsIgnoreEOL( $expected, $links );
    5252    }
    5353
     
    7474            )
    7575        );
    76         $this->assertEquals( $expected, $links );
     76        $this->assertEqualsIgnoreEOL( $expected, $links );
    7777    }
    7878
     
    101101            )
    102102        );
    103         $this->assertEquals( $expected, $links );
     103        $this->assertEqualsIgnoreEOL( $expected, $links );
    104104    }
    105105
Note: See TracChangeset for help on using the changeset viewer.