mediawiki-extensions-Templa.../tests/phpunit/TemplateStylesContentHandlerTest.php
Kunal Mehta 5ba45a396b Add @covers tags
Change-Id: Ie87849bc9dcc0b26363c9475930c967841e6a7f7
2018-02-05 18:19:30 -08:00

23 lines
650 B
PHP

<?php
/**
* @group TemplateStyles
* @covers TemplateStylesContentHandler
*/
class TemplateStylesContentHandlerTest extends MediaWikiLangTestCase {
public function testBasics() {
$handler = new TemplateStylesContentHandler();
$this->assertSame( 'sanitized-css', $handler->getModelID() );
$this->assertSame( [ 'text/css' ], $handler->getSupportedFormats() );
$this->assertInstanceOf( TemplateStylesContent::class, $handler->makeEmptyContent() );
$this->assertFalse( $handler->supportsRedirects() );
$title = Title::newFromText( 'Template:Example/styles.css' );
$this->assertNull( $handler->makeRedirectContent( $title ) );
}
}