case_name
case_name
The suffix that all TestCase methods need to have to be called by run()
Code used to test the summarizer algorithms.
__construct()
Contructor should be overriden to do any set up that occurs before and test cases
Warning: count(): Parameter must be an array or an object that implements Countable in phar:///Applications/MAMP/htdocs/git/phpDocumentor.phar/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1293 Warning: count(): Parameter must be an array or an object that implements Countable in phar:///Applications/MAMP/htdocs/git/phpDocumentor.phar/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1293run() : array
Execute each of the test cases of this unit test and return the results
Warning: count(): Parameter must be an array or an object that implements Countable in phar:///Applications/MAMP/htdocs/git/phpDocumentor.phar/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1293 Warning: count(): Parameter must be an array or an object that implements Countable in phar:///Applications/MAMP/htdocs/git/phpDocumentor.phar/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1293test case results
assertTrue(mixed $x, string $description = "")
Checks that $x can coerced to true, the result of the test is added to $this->test_case_results
mixed | $x | item to check |
string | $description | information about this test subcase |
assertFalse(mixed $x, string $description = "")
Checks that $x can coerced to false, the result of the test is added to $this->test_case_results
mixed | $x | item to check |
string | $description | information about this test subcase |
assertEqual(mixed $x, mixed $y, string $description = "")
Checks that $x and $y are the same, the result of the test is added to $this->test_case_results
mixed | $x | a first item to compare |
mixed | $y | a second item to compare |
string | $description | information about this test subcase |
assertNotEqual(mixed $x, mixed $y, string $description = "")
Checks that $x and $y are not the same, the result of the test is added to $this->test_case_results
mixed | $x | a first item to compare |
mixed | $y | a second item to compare |
string | $description | information about this test subcase |
setUp()
Each test we set up a new Summarizer object
Warning: count(): Parameter must be an array or an object that implements Countable in phar:///Applications/MAMP/htdocs/git/phpDocumentor.phar/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1293 Warning: count(): Parameter must be an array or an object that implements Countable in phar:///Applications/MAMP/htdocs/git/phpDocumentor.phar/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1293tearDown()
Nothing done for unit test tear done
Warning: count(): Parameter must be an array or an object that implements Countable in phar:///Applications/MAMP/htdocs/git/phpDocumentor.phar/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1293 Warning: count(): Parameter must be an array or an object that implements Countable in phar:///Applications/MAMP/htdocs/git/phpDocumentor.phar/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1293getAdditionalWeightTestCase()
This function reads each line from the $terms_and_html_tags file. The $terms_and_html_tags file contains a list of a term to search for and a sample html tag separated by a pipe. It parses each line from the $terms_and_html_tags file to and sends the arguments to the additionalWeights method. Then it compares the value returned to its corresponding value in the $return_values_to_compare file to make sure they match.
$return_values_to_compare is a list of corresponding values used for comparing results $terms_and_html_tags is a list of terms and the sample html tags to search matches
Warning: count(): Parameter must be an array or an object that implements Countable in phar:///Applications/MAMP/htdocs/git/phpDocumentor.phar/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1293 Warning: count(): Parameter must be an array or an object that implements Countable in phar:///Applications/MAMP/htdocs/git/phpDocumentor.phar/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1293