Make WordPress Core

Changeset 51938


Ignore:
Timestamp:
10/26/2021 02:02:50 AM (3 years ago)
Author:
SergeyBiryukov
Message:

Tests: Some test improvements for clean_dirsize_cache() tests:

  • Move the directory being tested to the data directory, for consistency with other test data.
  • Set the svn:eol-style property to native, for consistency with other files.
  • Correct the test class name in dummy.txt.

Follow-up to [51246], [51910], [51911].

See #52241, #53363.

Location:
trunk/tests/phpunit
Files:
2 edited
1 moved

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/data/functions/dummy.txt

    • Property svn:eol-style changed from CR to native
    r51911 r51938  
    1 This is a dummy text file which is only used by the `Tests_Multisite_CleanDirsizeCache::test_recurse_dirsize_without_transient()` test.
     1This is a dummy text file which is only used by the `Tests_Functions_CleanDirsizeCache::test_recurse_dirsize_without_transient()` test.
  • trunk/tests/phpunit/tests/functions/cleanDirsizeCache.php

    • Property svn:eol-style changed from CR to native
    r51911 r51938  
    116116        delete_transient( 'dirsize_cache' );
    117117
    118         $size = recurse_dirsize( __DIR__ . '/fixtures' );
     118        $size = recurse_dirsize( DIR_TESTDATA . '/functions' );
    119119
    120120        $this->assertGreaterThan( 10, $size );
     
    134134        set_transient( 'dirsize_cache', 'this is not a valid transient for dirsize cache' );
    135135
    136         $size = recurse_dirsize( __DIR__ . '/fixtures' );
     136        $size = recurse_dirsize( DIR_TESTDATA . '/functions' );
    137137
    138138        $this->assertGreaterThan( 10, $size );
Note: See TracChangeset for help on using the changeset viewer.