1 | <?php |
||
8 | class LocationTest extends TestCase |
||
9 | { |
||
10 | public function testBarcode() |
||
11 | { |
||
12 | $location = new Location(0, 0); |
||
13 | |||
14 | $location |
||
15 | ->setAltitude(100) |
||
16 | ->setRelevantText('text') |
||
17 | ; |
||
18 | |||
19 | $this->assertEquals(0, $location->getLatitude()); |
||
20 | $this->assertEquals(0, $location->getLongitude()); |
||
21 | |||
22 | $expected = [ |
||
23 | 'latitude' => 0, |
||
24 | 'longitude' => 0, |
||
25 | 'altitude' => 100, |
||
26 | 'relevantText' => 'text' |
||
27 | ]; |
||
28 | |||
29 | $this->assertEquals($expected, $location->toArray()); |
||
30 | } |
||
31 | } |