- /**
- * @covers ContentHandler::runLegacyHooks
- */
- public function testRunLegacyHooks() {
- Hooks::register( 'testRunLegacyHooks', __CLASS__ . '::dummyHookHandler' );
-
- $content = new WikitextContent( 'test text' );
- $ok = ContentHandler::runLegacyHooks(
- 'testRunLegacyHooks',
- [ 'foo', &$content, 'bar' ]
- );
-
- $this->assertTrue( $ok, "runLegacyHooks should have returned true" );
- $this->assertEquals( "TEST TEXT", $content->getNativeData() );
- }
-