Add Content::matchMagicWord
[lhc/web/wiklou.git] / tests / phpunit / includes / JavascriptContentTest.php
index cb40e76..84cde8c 100644 (file)
@@ -214,6 +214,13 @@ class JavascriptContentTest extends WikitextContentTest {
                );
        }
 
+       public function testMatchMagicWord( ) {
+               $mw = MagicWord::get( "staticredirect" );
+
+               $content = $this->newContent( "#REDIRECT [[FOO]]\n__STATICREDIRECT__" );
+               $this->assertFalse( $content->matchMagicWord( $mw ), "should not have matched magic word, since it's not wikitext" );
+       }
+
        # =================================================================================================================
 
        public function testGetModel() {