xref: /dokuwiki/lib/plugins/testing/action.php (revision cbb44eabe033d70affb048ec0daf4e579e09dd20)
1f693efbcSTobias Sarnowski<?php
2*cbb44eabSAndreas Gohr
3*cbb44eabSAndreas Gohruse dokuwiki\Extension\Event;
4*cbb44eabSAndreas 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() {
20f693efbcSTobias Sarnowski        $param = array();
21*cbb44eabSAndreas 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