Make WordPress Core


Ignore:
Timestamp:
03/26/2019 12:45:57 AM (5 years ago)
Author:
johnbillion
Message:

Build/Test tools: Fix the Travis CI build for the 4.0 branch.

Among other fixes, this backports [29860], [29869], [29954], [30160], [30530].

Fixes #46646

Location:
branches/4.0
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/4.0

  • branches/4.0/tests/phpunit/tests/functions.php

    r29342 r45013  
    130130        $this->assertEquals( 'abcdefg.png', wp_unique_filename( $testdir, 'abcde\\fg.png' ), 'Double slashed not removed' );
    131131        $this->assertEquals( 'abcdefg.png', wp_unique_filename( $testdir, 'abcde\\\fg.png' ), 'Tripple slashed not removed' );
    132     }
    133 
    134     /**
    135      * @ticket 9930
    136      */
    137     function test_is_serialized() {
    138         $cases = array(
    139             serialize(null),
    140             serialize(true),
    141             serialize(false),
    142             serialize(-25),
    143             serialize(25),
    144             serialize(1.1),
    145             serialize(2.1E+200),
    146             serialize('this string will be serialized'),
    147             serialize("a\nb"),
    148             serialize(array()),
    149             serialize(array(1,1,2,3,5,8,13)),
    150             serialize( (object)array('test' => true, '3', 4) )
    151         );
    152         foreach ( $cases as $case )
    153             $this->assertTrue( is_serialized($case), "Serialized data: $case" );
    154 
    155         $not_serialized = array(
    156             'a string',
    157             'garbage:a:0:garbage;',
    158             'b:4;',
    159             's:4:test;'
    160         );
    161         foreach ( $not_serialized as $case )
    162             $this->assertFalse( is_serialized($case), "Test data: $case" );
    163132    }
    164133
Note: See TracChangeset for help on using the changeset viewer.