Make WordPress Core

Ticket #31441: 31441.17.patch

File 31441.17.patch, 2.9 KB (added by iseulde, 10 years ago)
  • src/wp-admin/css/press-this.css

     
    846846        border-bottom: 1px solid #e5e5e5;
    847847        font-size: 14px;
    848848        -webkit-appearance: none;
     849        -moz-appearance: none;
    849850        appearance: none;
    850851}
    851852
  • tests/qunit/wp-includes/js/tinymce/plugins/wptextpattern/plugin.js

     
    11( function( $, QUnit, tinymce, _type, setTimeout ) {
    2         var editor;
     2        var editor,
     3                count = 0;
    34
    45        if ( tinymce.Env.ie && tinymce.Env.ie < 9 ) {
    56                return;
     
    3132
    3233        QUnit.module( 'tinymce.plugins.wptextpattern', {
    3334                beforeEach: function( assert ) {
    34                         var done = assert.async();
     35                        var done;
    3536
    36                         $( '#qunit-fixture' ).append( '<textarea id="editor">' );
     37                        if ( ! editor ) {
     38                                done = assert.async();
    3739
    38                         tinymce.init( {
    39                                 selector: '#editor',
    40                                 plugins: 'wptextpattern',
    41                                 init_instance_callback: function() {
    42                                         editor = arguments[0];
    43                                         editor.focus();
    44                                         editor.selection.setCursorLocation();
    45                                         setTimeout( done );
    46                                 }
    47                         } );
     40                                $( document.body ).append( '<textarea id="editor">' );
     41
     42                                tinymce.init( {
     43                                        selector: '#editor',
     44                                        skin: false,
     45                                        plugins: 'wptextpattern',
     46                                        init_instance_callback: function() {
     47                                                editor = arguments[0];
     48                                                editor.focus();
     49                                                editor.selection.setCursorLocation();
     50                                                done();
     51                                        }
     52                                } );
     53                        } else {
     54                                editor.setContent( '' );
     55                                editor.selection.setCursorLocation();
     56                        }
    4857                },
    49                 afterEach: function() {
    50                         editor.remove();
     58                afterEach: function( assert ) {
     59                        count++;
     60
     61                        if ( count === assert.test.module.tests.length ) {
     62                                editor.remove();
     63                                $( '#editor' ).remove();
     64                        }
    5165                }
    5266        } );
    5367
    5468        QUnit.test( 'Unordered list.', function( assert ) {
    55                 type( '* test', function() {
    56                         assert.equal( editor.getContent(), '<ul>\n<li>test</li>\n</ul>' );
     69                type( '* a', function() {
     70                        assert.equal( editor.getContent(), '<ul>\n<li>a</li>\n</ul>' );
    5771                }, assert.async() );
    5872        } );
    5973
    6074        QUnit.test( 'Ordered list.', function( assert ) {
    61                 type( '1. test', function() {
    62                         assert.equal( editor.getContent(), '<ol>\n<li>test</li>\n</ol>' );
     75                type( '1. a', function() {
     76                        assert.equal( editor.getContent(), '<ol>\n<li>a</li>\n</ol>' );
    6377                }, assert.async() );
    6478        } );
    6579
     
    94108                editor.setContent( '<p>* test</p>' );
    95109                editor.selection.setCursorLocation( editor.$( 'p' )[0].firstChild, 6 );
    96110
    97                 type( ' test', function() {
    98                         assert.equal( editor.getContent(), '<p>* test test</p>' );
     111                type( ' a', function() {
     112                        assert.equal( editor.getContent(), '<p>* test a</p>' );
    99113                }, assert.async() );
    100114        } );
    101115