Index: tests/phpunit/tests/media.php
===================================================================
--- tests/phpunit/tests/media.php	(revision 27500)
+++ tests/phpunit/tests/media.php	(working copy)
@@ -108,6 +108,20 @@
 		$this->assertEquals( 1, preg_match_all( "~wp-caption-text.*{$content_preg}~", $result, $_r ) );
 	}
 
+	/**
+	 * @ticket 26642
+	 */
+	function test_new_img_caption_shortcode_new_format_no_inline() {
+		add_theme_support( 'no-inline-style-captions' );
+		$result = img_caption_shortcode(
+			array( 'width' => 20 ),
+			$this->img_content . $this->html_content
+		);
+		$expected = '<div class="wp-caption alignnone">' . $this->img_content . '<p class="wp-caption-text">' . $this->html_content . '</p></div>';
+		$this->assertEquals( $expected, $result );
+		remove_theme_support( 'no-inline-style-captions' );
+	}
+
 	function test_add_remove_oembed_provider() {
 		wp_oembed_add_provider( 'http://foo.bar/*', 'http://foo.bar/oembed' );
 		$this->assertTrue( wp_oembed_remove_provider( 'http://foo.bar/*' ) );
