Definition at line 10 of file EntriesYamlParserTest.php.
◆ setUp()
◆ testCamelCase()
CrawlerTest::testCamelCase |
( |
| ) |
|
Definition at line 98 of file EntriesYamlParserTest.php.
100 $test_string =
"Hello Camel Case";
102 $this->assertEquals(
"helloCamelCase",
Crawler\EntriesYamlParser::toLowerCamelCase($test_string,
' '));
103 $this->assertEquals(
"HelloCamelCase",
Crawler\EntriesYamlParser::toUpperCamelCase($test_string,
' '));
◆ testGenerateEntry()
CrawlerTest::testGenerateEntry |
( |
| ) |
|
- Exceptions
-
Definition at line 109 of file EntriesYamlParserTest.php.
111 $entries = $this->parser->parseEntriesFromFile(
"tests/UI/Crawler/Fixture/ProperEntry.php");
113 $this->assertEquals(1, count($entries));
114 $this->assertEquals(
"CrawlerFixtureProperEntryProperEntry", $entries->getEntryById(
"CrawlerFixtureProperEntryProperEntry")->getId());
115 $this->assertEquals(
"src/UI/Crawler/Fixture/ProperEntry", $entries->getEntryById(
"CrawlerFixtureProperEntryProperEntry")->getPath());
◆ testInvalidYamlEntry()
CrawlerTest::testInvalidYamlEntry |
( |
| ) |
|
- Exceptions
-
Definition at line 88 of file EntriesYamlParserTest.php.
References Vendor\Package\$e.
91 $this->parser->parseArrayFromFile(
"tests/UI/Crawler/Fixture/InvalidYamlEntry.php");
92 $this->assertFalse(
"This should not happen");
94 $this->assertEquals($e->getCode(), Crawler\Exception\CrawlerException::PARSING_YAML_ENTRY_FAILED);
◆ testNoDescriptionEntry()
CrawlerTest::testNoDescriptionEntry |
( |
| ) |
|
- Exceptions
-
Definition at line 63 of file EntriesYamlParserTest.php.
References Vendor\Package\$e.
66 $this->parser->parseYamlStringArrayFromFile(
"tests/UI/Crawler/Fixture/NoDescriptionEntry.php");
67 $this->assertFalse(
"This should not happen");
69 $this->assertEquals($e->getCode(), Crawler\Exception\CrawlerException::ENTRY_WITH_NO_YAML_DESCRIPTION);
◆ testNoReturnValueEntry()
CrawlerTest::testNoReturnValueEntry |
( |
| ) |
|
- Exceptions
-
Definition at line 75 of file EntriesYamlParserTest.php.
References Vendor\Package\$e.
78 $this->parser->parseYamlStringArrayFromFile(
"tests/UI/Crawler/Fixture/NoReturnValueEntry.php");
79 $this->assertFalse(
"This should not happen");
81 $this->assertEquals($e->getCode(), Crawler\Exception\CrawlerException::ENTRY_WITH_NO_VALID_RETURN_STATEMENT);
◆ testParseInvalidFile()
CrawlerTest::testParseInvalidFile |
( |
| ) |
|
- Exceptions
-
Definition at line 33 of file EntriesYamlParserTest.php.
References Vendor\Package\$e.
36 $this->parser->parseYamlStringArrayFromFile(
"Invalid Path");
37 $this->assertFalse(
"This should not happen");
39 $this->assertEquals($e->getCode(), Crawler\Exception\CrawlerException::INVALID_FILE_PATH);
◆ testParseProperEntryToArray()
CrawlerTest::testParseProperEntryToArray |
( |
| ) |
|
Definition at line 54 of file EntriesYamlParserTest.php.
56 $entries = $this->parser->parseArrayFromFile(
"tests/UI/Crawler/Fixture/ProperEntry.php");
57 $this->assertEquals($this->proper_entry->properEntryYamlArray, $entries);
◆ testParseProperEntryToYamlEntries()
CrawlerTest::testParseProperEntryToYamlEntries |
( |
| ) |
|
- Exceptions
-
Definition at line 46 of file EntriesYamlParserTest.php.
48 $yaml_entries = $this->parser->parseYamlStringArrayFromFile(
"tests/UI/Crawler/Fixture/ProperEntry.php");
50 $this->assertEquals($this->proper_entry->properEntryYamlString, $yaml_entries[0]);
51 $this->assertEquals($this->proper_entry->properEntryYamlString, $yaml_entries[0]);
◆ $parser
◆ $proper_entry
CrawlerTest::$proper_entry |
|
protected |
The documentation for this class was generated from the following file: