WordPress.org

Make WordPress Core

Changeset 689 in tests


Ignore:
Timestamp:
04/19/2012 02:05:57 PM (6 years ago)
Author:
nacin
Message:

Test cases for #WP20488.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wp-testcase/test_includes_capabilities.php

    r521 r689  
    191191    }
    192192
     193    function test_file_edit_caps_not_reliant_on_unfiltered_html_constant() {
     194        $this->knownWPBug(20488);
     195        define( 'DISALLOW_UNFILTERED_HTML', true );
     196        if ( defined( 'DISALLOW_FILE_MODS' ) || defined( 'DISALLOW_FILE_EDIT' ) )
     197            $this->markTestSkipped('DISALLOW_FILE_MODS or DISALLOW_FILE_EDIT is defined.');
     198        $this->assertEquals( array( 'update_core' ), map_meta_cap( 'update_core', $this->user_id ) );
     199        $this->assertEquals( array( 'edit_plugins' ), map_meta_cap( 'edit_plugins', $this->user_id ) );
     200    }
    193201}
    194202
Note: See TracChangeset for help on using the changeset viewer.