4 * @group ContentHandler
7 * ^--- needed, because we do need the database to test link updates
9 class CssContentTest
extends JavascriptContentTest
{
11 public function newContent( $text ) {
12 return new CssContent( $text );
16 public function dataGetParserOutput() {
18 array("MediaWiki:Test.css", null, "hello <world>\n",
19 "<pre class=\"mw-code mw-css\" dir=\"ltr\">\nhello <world>\n\n</pre>\n"),
25 # =================================================================================================================
27 public function testGetModel() {
28 $content = $this->newContent( "hello world." );
30 $this->assertEquals( CONTENT_MODEL_CSS
, $content->getModel() );
33 public function testGetContentHandler() {
34 $content = $this->newContent( "hello world." );
36 $this->assertEquals( CONTENT_MODEL_CSS
, $content->getContentHandler()->getModelID() );
39 public function dataEquals( ) {
41 array( new CssContent( "hallo" ), null, false ),
42 array( new CssContent( "hallo" ), new CssContent( "hallo" ), true ),
43 array( new CssContent( "hallo" ), new WikitextContent( "hallo" ), false ),
44 array( new CssContent( "hallo" ), new CssContent( "HALLO" ), false ),