xref: /dokuwiki/lib/plugins/testing/action.php (revision 54cc7aa41e0f453bd6887b0e79242a139d84a47a)
1f693efbcSTobias Sarnowski<?php
2cbb44eabSAndreas Gohr
3cbb44eabSAndreas Gohruse dokuwiki\Extension\Event;
4cbb44eabSAndreas Gohr
523684d4aSAndreas Gohr/**
623684d4aSAndreas Gohr * Plugin for testing the test system
723684d4aSAndreas Gohr *
823684d4aSAndreas Gohr * This plugin doesn't really do anything and should always be disabled
923684d4aSAndreas Gohr *
1023684d4aSAndreas Gohr * @author Tobias Sarnowski <tobias@trustedco.de>
1123684d4aSAndreas Gohr */
12f693efbcSTobias Sarnowskiclass action_plugin_testing extends DokuWiki_Action_Plugin {
13e8b5a4f9SAndreas Gohr
143dc2d50cSAndreas Gohr    /** @inheritdoc */
153dc2d50cSAndreas Gohr    public function register(Doku_Event_Handler $controller) {
16f693efbcSTobias Sarnowski        $controller->register_hook('DOKUWIKI_STARTED', 'AFTER', $this, 'dokuwikiStarted');
17f693efbcSTobias Sarnowski    }
18f693efbcSTobias Sarnowski
193dc2d50cSAndreas Gohr    public function dokuwikiStarted() {
20*54cc7aa4SAndreas Gohr        $param = [];
21cbb44eabSAndreas Gohr        Event::createAndTrigger('TESTING_PLUGIN_INSTALLED', $param);
2223684d4aSAndreas Gohr        msg('The testing plugin is enabled and should be disabled.',-1);
23f693efbcSTobias Sarnowski    }
24f693efbcSTobias Sarnowski}
25