Exemplo n.º 1
0
 protected function setUp()
 {
     global $PAGE;
     parent::setUp();
     $this->renderer = $PAGE->get_renderer('qbehaviour_adaptive');
     $this->options = new question_display_options();
 }
Exemplo n.º 2
0
 /**
  * Initalize test wide variable, it is called in start of the testcase
  */
 protected function setUp()
 {
     parent::setUp();
     // Get form data.
     $form = new temp_form_duration();
     $this->mform = $form->getform();
     $this->element = $this->mform->addElement('duration', 'duration');
 }
Exemplo n.º 3
0
    protected function tearDown() {
        global $DB,$CFG,$SESSION,$USER;
        $DB = $this->realdb;
        $CFG = $this->realcfg;
        $SESSION = $this->realsession;
        $USER = $this->prevuser;

        parent::tearDown();
    }
Exemplo n.º 4
0
 protected function setUp()
 {
     parent::setUp();
     if ($this->getName() === 'test_setup_assert') {
         $this->assertTrue(true);
         $this->testassertexecuted = true;
         return;
     }
 }
Exemplo n.º 5
0
 /**
  * Cleans things up after this test case has run.
  */
 protected function tearDown()
 {
     global $SESSION;
     parent::tearDown();
     if ($this->initiallang !== null) {
         $SESSION->lang = $this->initiallang;
         $this->initiallang = null;
     } else {
         unset($SESSION->lang);
     }
 }
Exemplo n.º 6
0
 protected function tearDown() {
     $this->testpage = null;
     $this->blockmanager = null;
     parent::tearDown();
 }
Exemplo n.º 7
0
 public function setUp()
 {
     parent::setUp();
     $this->behaviourtype = question_engine::get_behaviour_type('interactivecountback');
 }
Exemplo n.º 8
0
 public function setUp()
 {
     parent::setUp();
     $this->behaviourtype = question_engine::get_behaviour_type('immediatefeedback');
 }
Exemplo n.º 9
0
 public function setUp()
 {
     parent::setUp();
     $this->behaviourtype = question_engine::get_behaviour_type('informationitem');
 }
Exemplo n.º 10
0
 protected function tearDown()
 {
     $this->workshop = null;
     $this->evaluator = null;
     parent::tearDown();
 }
Exemplo n.º 11
0
    protected function setUp() {
        parent::setUp();

        $this->cache = new navigation_cache('simpletest_nav');
        $this->cache->anysetvariable = true;
    }
Exemplo n.º 12
0
 public function setUp()
 {
     parent::setUp();
     $this->behaviourtype = question_engine::get_behaviour_type('manualgraded');
 }
Exemplo n.º 13
0
 /**
  * Sets up the test cases.
  */
 protected function setUp()
 {
     parent::setUp();
     $this->filter = new filter_oembed(context_system::instance(), array());
 }
Exemplo n.º 14
0
 public function setUp()
 {
     parent::setUp();
     $this->behaviourtype = question_engine::get_behaviour_type('missing');
 }
Exemplo n.º 15
0
 /**
  * Clears the data set in the setUp() method call.
  * @see dateselector_form_element_testcase::setUp()
  */
 protected function tearDown()
 {
     unset($this->testvals);
     parent::tearDown();
 }
Exemplo n.º 16
0
 /**
  * Initalize test wide variable, it is called in start of the testcase
  */
 protected function setUp()
 {
     parent::setUp();
     $this->element = new MoodleQuickForm_duration();
 }