[ Index ]

PHP Cross Reference of Unnamed Project

title

Body

[close]

/question/type/randomsamatch/tests/ -> helper.php (summary)

Test helpers for the randomsamatch question type.

Copyright: 2013 Jean-Michel Vedrine
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 139 lines (6 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 2 classes

qtype_randomsamatch_test_helper:: (2 methods):
  get_test_questions()
  make_randomsamatch_question_animals()

qtype_randomsamatch_test_question_loader:: (2 methods):
  __construct()
  load_questions()


Class: qtype_randomsamatch_test_helper  - X-Ref

Test helper class for the randomsamatch question type.

get_test_questions()   X-Ref
No description

make_randomsamatch_question_animals()   X-Ref
Makes a randomsamatch question similar to the match question returned
by {@link make_a_matching_question}, but with no 'insect' distractor.

return: qtype_randomsamatch_question

Class: qtype_randomsamatch_test_question_loader  - X-Ref

Test implementation of {@link qtype_randomsamatch_question_loader}. Gets the questions
from an array passed to the constructor, rather than querying the database.

__construct($availablequestions, $choose, $questions)   X-Ref
Constructor

param: array $availablequestions not used for tests.
param: int $choose how many questions to load (not used here).
param: array $questions array of questions to use.

load_questions()   X-Ref
Just return the shortanswers questions passed to the constructor.

return: array of short answer questions.



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