[ Index ]

PHP Cross Reference of Unnamed Project

title

Body

[close]

/question/engine/upgrade/tests/ -> helper.php (summary)

This file contains test helper code for testing the upgrade to the new question engine. The acutal tests are organised by question type in files like question/type/truefalse/tests/upgradelibnewqe_test.php.

Copyright: 2009 The Open University
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 141 lines (5 kb)
Included or required:0 times
Referenced: 7 times
Includes or requires: 1 file
 question/engine/upgrade/upgradelib.php

Defines 2 classes

test_question_engine_attempt_upgrader:: (2 methods):
  prevent_timeout()
  __construct()

test_question_engine_upgrade_question_loader:: (8 methods):
  put_question_in_cache()
  load_question()
  put_dataset_in_cache()
  load_dataset()
  setUp()
  tearDown()
  clear_html2text_dependencies()
  compare_qas()


Class: test_question_engine_attempt_upgrader  - X-Ref

Subclass of question_engine_attempt_upgrader to help with testing.

prevent_timeout()   X-Ref
No description

__construct($loader, $logger)   X-Ref
No description

Class: test_question_engine_upgrade_question_loader  - X-Ref

Subclass of question_engine_upgrade_question_loader for unit testing.

put_question_in_cache($question)   X-Ref
No description

load_question($questionid, $quizid)   X-Ref
No description

put_dataset_in_cache($questionid, $selecteditem, $dataset)   X-Ref
No description

load_dataset($questionid, $selecteditem)   X-Ref
No description

setUp()   X-Ref
No description

tearDown()   X-Ref
No description

clear_html2text_dependencies($qa)   X-Ref
Clear text, bringing independence of html2text results

Some tests performing text comparisons of converted text are too much
dependent of the behavior of the html2text library. This function is
aimed to reduce such dependencies that should not affect the results
of these question attempt upgrade tests.

compare_qas($expectedqa, $qa)   X-Ref
Compare two qas, ignoring inessential differences.

param: object $expectedqa the expected qa.
param: object $qa the actual qa.



Generated: Thu Aug 11 10:00:09 2016 Cross-referenced by PHPXref 0.7.1