Commit b6c0c857 authored by Dainis Abols's avatar Dainis Abols
Browse files

LessonsTest changes

parent 92b880d6
......@@ -66,7 +66,7 @@ class LessonsTest extends UnitTestCase
$this->assertTrue($structure($content), 'Lessons structure does not match');
// Check items object
$this->assertNotEmpty($content['items'], 'Lessons has no items received');
$this->assertNotEmpty($content['items'], 'Lessons has no items received. Check if lectures are present!');
// Check data object structure
$this->assertTrue(count($content['items'][0]) === 9, 'Lessons items count does not match');
......@@ -82,7 +82,7 @@ class LessonsTest extends UnitTestCase
public function lessonsSingleRoomJSONTest()
{
// Get room url
$url = $this->url.'zinatnu-maja/search';
$url = $this->url.'dabas-maja/search';
$result = (new DataHelper())->fetchUrl($url);
$content = @$result->getBody()->getContents();
$content = json_decode($content, true);
......@@ -123,7 +123,7 @@ class LessonsTest extends UnitTestCase
public function lessonsHTMLTest()
{
// Read url
$url = $this->url.'dabas-maja/search&visual=1';
$url = $this->url.'zinatnu-maja/search&visual=1';
$result = (new DataHelper())->fetchUrl($url);
// Assert url read
......@@ -138,13 +138,13 @@ class LessonsTest extends UnitTestCase
/**
* Single room lessons (JSON) test
*
* @depends lessonsHTMLTest
* @depends lessonsJSONTest
* @test
*/
public function lessonsSingleRoomHTMLTest()
{
// Get room url
$url = $this->url.'zinatnu-maja/search';
$url = $this->url.'dabas-maja/search';
$result = (new DataHelper())->fetchUrl($url);
$content = @$result->getBody()->getContents();
$content = json_decode($content, true);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment