WordPress.org

Make WordPress Core

Changeset 305 in tests


Ignore:
Timestamp:
05/20/10 21:15:29 (4 years ago)
Author:
westi
Message:

Updated and extra tests for WP#12860.

Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • wp-testcase/test_import_wp.php

    r303 r305  
    28572857        $this->assertEquals($expected, get_post_meta(122, 'post-options', true)); 
    28582858    } 
     2859     
     2860    function test_utw_postmeta() { 
     2861        //test-utw-post-meta-import.xml 
     2862        $this->knownWPBug(12860); 
     2863        $html_output = get_echo( array(&$this, '_import_wp'), array( DIR_TESTDATA.'/export/test-utw-post-meta-import.xml', array('User A') ) ); 
     2864 
     2865        $classy = new StdClass(); 
     2866        $classy->tag =  "album"; 
     2867        $expected[] = $classy; 
     2868        $classy = new StdClass(); 
     2869        $classy->tag =  "apple"; 
     2870        $expected[] = $classy; 
     2871        $classy = new StdClass(); 
     2872        $classy->tag =  "art"; 
     2873        $expected[] = $classy; 
     2874        $classy = new StdClass(); 
     2875        $classy->tag =  "artwork"; 
     2876        $expected[] = $classy;   
     2877        $classy = new StdClass(); 
     2878        $classy->tag =  "dead-tracks"; 
     2879        $expected[] = $classy;   
     2880        $classy = new StdClass(); 
     2881        $classy->tag =  "ipod"; 
     2882        $expected[] = $classy; 
     2883        $classy = new StdClass(); 
     2884        $classy->tag =  "itunes"; 
     2885        $expected[] = $classy; 
     2886        $classy = new StdClass(); 
     2887        $classy->tag =  "javascript"; 
     2888        $expected[] = $classy; 
     2889        $classy = new StdClass(); 
     2890        $classy->tag =  "lyrics"; 
     2891        $expected[] = $classy;   
     2892        $classy = new StdClass(); 
     2893        $classy->tag =  "script"; 
     2894        $expected[] = $classy;   
     2895        $classy = new StdClass(); 
     2896        $classy->tag =  "tracks"; 
     2897        $expected[] = $classy;   
     2898        $classy = new StdClass(); 
     2899        $classy->tag =  "windows-scripting-host"; 
     2900        $expected[] = $classy;   
     2901        $classy = new StdClass(); 
     2902        $classy->tag =  "wscript"; 
     2903        $expected[] = $classy;   
     2904         
     2905        $this->assertEquals($expected, get_post_meta(150, 'test', true)); 
     2906    } 
    28592907} 
    28602908 
  • wp-testcase/test_includes_post.php

    r304 r305  
    761761        $this->knownWPBug(12860); 
    762762         
    763         $funky_meta[] = new StdClass(); 
    764         $funky_meta[] = new StdClass(); 
     763        $classy = new StdClass(); 
     764        $classy->ID = 1; 
     765        $classy->stringy = "I love slashes\\\\"; 
     766        $funky_meta[] = $classy; 
     767         
     768        $classy = new StdClass(); 
     769        $classy->ID = 2; 
     770        $classy->stringy = "I love slashes\\\\ more"; 
     771        $funky_meta[] = $classy; 
    765772         
    766773        // Add a post meta item 
Note: See TracChangeset for help on using the changeset viewer.