Make WordPress Core

Ticket #23431: 23431.3.diff

File 23431.3.diff, 1.6 KB (added by desrosj, 2 years ago)
  • src/wp-content/themes/twentynineteen/style.css

    diff --git a/src/wp-content/themes/twentynineteen/style.css b/src/wp-content/themes/twentynineteen/style.css
    index 9d68322d74..0e498df162 100644
    a b svg { 
    66156615.gallery-item > div > a:focus {
    66166616  box-shadow: 0 0 0 2px #0073aa;
    66176617}
     6618.testing {
     6619        color: blue;
     6620}
     6621 No newline at end of file
  • src/wp-includes/class-wp-embed.php

    diff --git a/src/wp-includes/class-wp-embed.php b/src/wp-includes/class-wp-embed.php
    index 677a5944c4..55b8e49e5b 100644
    a b class WP_Embed { 
    3434                add_filter( 'widget_block_content', array( $this, 'run_shortcode' ), 8 );
    3535
    3636                // Shortcode placeholder for strip_shortcodes().
    37                 add_shortcode( 'embed', '__return_false' );
     37                add_shortcode( 'embed', array( $this, 'shortcode' ) );
    3838
    3939                // Attempts to embed all URLs in a post.
    4040                add_filter( 'the_content', array( $this, 'autoembed' ), 8 );
  • tests/phpunit/tests/oembed/WpEmbed.php

    diff --git a/tests/phpunit/tests/oembed/WpEmbed.php b/tests/phpunit/tests/oembed/WpEmbed.php
    index 239ea24d56..1be7900e83 100644
    a b class Tests_WP_Embed extends WP_UnitTestCase { 
    377377                $this->wp_embed->linkifunknown = false;
    378378                $this->assertSame( $url, $this->wp_embed->maybe_make_link( $url ) );
    379379        }
     380
     381        /**
     382         * @ticket 23431
     383         */
     384        public function test_embed_shortcode() {
     385                $content = '[embed]https://example.org/path/to/video[/embed]';
     386                $this->assertNotEmpty( do_shortcode( $content ) );
     387        }
    380388}