* ^--- important, causes temporary tables to be used instead of the real database
*/
class RevisionTest_ContentHandlerUseDB extends RevisionStorageTest {
- var $saveContentHandlerNoDB = null;
- function setUp() {
- global $wgContentHandlerUseDB;
-
- $this->saveContentHandlerNoDB = $wgContentHandlerUseDB;
-
- $wgContentHandlerUseDB = false;
+ protected function setUp() {
+ $this->setMwGlobals( 'wgContentHandlerUseDB', false );
$dbw = wfGetDB( DB_MASTER );
parent::setUp();
}
- function tearDown() {
- global $wgContentHandlerUseDB;
-
- parent::tearDown();
-
- $wgContentHandlerUseDB = $this->saveContentHandlerNoDB;
- }
-
/**
* @covers Revision::selectFields
*/
*/
public function testGetContentFormat() {
try {
- //@todo: change this to test failure on using a non-standard (but supported) format
+ // @todo change this to test failure on using a non-standard (but supported) format
// for a content model supported in the given location. As of 1.21, there are
// no alternative formats for any of the standard content models that could be
// used for this though.
$this->assertTrue( true ); // ok
}
}
-
}