. /** * PHPunit implementation unit tests * * @package core * @category phpunit * @copyright 2012 Petr Skoda {@link http://skodak.org} * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later */ defined('MOODLE_INTERNAL') || die(); /** * Test integration of PHPUnit and custom Moodle hacks. * * @package core * @category phpunit * @copyright 2012 Petr Skoda {@link http://skodak.org} * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later */ class core_phpunit_basic_testcase extends basic_testcase { /** * Tests that bootstraping has occurred correctly * @return void */ public function test_bootstrap() { global $CFG; $this->assertTrue(isset($CFG->httpswwwroot)); $this->assertEquals($CFG->httpswwwroot, $CFG->wwwroot); $this->assertEquals($CFG->prefix, $CFG->phpunit_prefix); } /* public function test_borked_tests() { global $DB; $DB->set_field('user', 'confirmed', 1, array('id'=>-1)); $CFG->xx = 'yy'; } */ }