[moodle] / contrib / plugins / question / type / sojunit / simpletest / testquestiontype.php Repository:

View of /contrib/plugins/question/type/sojunit/simpletest/testquestiontype.php

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (download) (annotate)
Sun Oct 26 08:48:51 2008 WST (12 months, 3 weeks ago) by arborrow
Branch: MAIN
CVS Tags: HEAD
CONTRIB-689 - adding sojunit question type. Thanks to Süreç Özcan for contributing and maintaining this code.
<?php
/**
 * Unit tests for this question type.
 *
 * @copyright &copy; 2008 Süreç Özcan
 * @author suerec@darkjade.net
 * @license http://www.gnu.org/copyleft/gpl.html GNU Public License
 * @package so_questiontypes
 *//** */
    
require_once(dirname(__FILE__) . '/../../../../config.php');

global $CFG;
require_once($CFG->libdir . '/simpletestlib.php');
require_once($CFG->dirroot . '/question/type/sojunit/questiontype.php');

class sojunit_qtype_test extends UnitTestCase {
    var $qtype;
    
    function setUp() {
        $this->qtype = new sojunit_qtype();
    }
    
    function tearDown() {
        $this->qtype = null;    
    }

    function test_name() {
        $this->assertEqual($this->qtype->name(), 'sojunit');
    }
    
    // TODO write unit tests for the other methods of the question type class.
}

?>

Moodle CVS Admin
ViewVC Help
Powered by ViewVC 1.0.7