WordPress.org

Make WordPress Core

Changeset 742 in tests


Ignore:
Timestamp:
06/25/12 21:14:57 (22 months ago)
Author:
nacin
Message:

Test case for #WP20955. Combine two duplicated tests.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wp-testcase/test_admin_includes_theme.php

    r737 r742  
    3535    function test_page_templates() { 
    3636        $this->knownWPBug(10959); 
    37         $theme = get_theme('Page Template Theme'); 
    38         $this->assertFalse( empty($theme) ); 
    39  
    40         switch_theme($theme['Template'], $theme['Stylesheet']); 
    41  
    42         $templates = get_page_templates(); 
    43         $this->assertEquals(2, count($templates)); 
    44         $this->assertEquals("template-top-level.php", $templates['Top Level']); 
    45     } 
    46  
    47     function test_page_templates_subdir() { 
    4837        $this->knownWPBug(11216); 
    4938        $theme = get_theme('Page Template Theme'); 
     
    5342 
    5443        $templates = get_page_templates(); 
    55         $this->assertEquals(2, count($templates)); 
     44        $this->assertEquals(3, count($templates)); 
    5645        $this->assertEquals("template-top-level.php", $templates['Top Level']); 
    5746        $this->assertEquals("subdir/template-sub-dir.php", $templates['Sub Dir']); 
     47        $this->assertEquals("template-header.php", $templates['This Template Header Is On One Line']); 
    5848    } 
    5949} 
Note: See TracChangeset for help on using the changeset viewer.