Code Duplication    Length = 12-12 lines in 2 locations

tests/Rdata/LocTest.php 2 locations

@@ 35-46 (lines=12) @@
32
        $this->assertEquals($expected, $rdata->toText());
33
    }
34
35
    public function testSetLatitude(): void
36
    {
37
        $latitude = -35.3075;
38
        $lat_dms = '35 18 27.000 S';
39
40
        $rdata = new LOC();
41
        $rdata->setLatitude($latitude);
42
43
        $this->assertEquals($latitude, $rdata->getLatitude());
44
        $this->assertEquals($latitude, $rdata->getLatitude(LOC::FORMAT_DECIMAL));
45
        $this->assertEquals($lat_dms, $rdata->getLatitude(LOC::FORMAT_DMS));
46
    }
47
48
    public function testSetLongitude(): void
49
    {
@@ 48-59 (lines=12) @@
45
        $this->assertEquals($lat_dms, $rdata->getLatitude(LOC::FORMAT_DMS));
46
    }
47
48
    public function testSetLongitude(): void
49
    {
50
        $longitude = 149.1244;
51
        $lon_dms = '149 7 27.840 E';
52
53
        $rdata = new LOC();
54
        $rdata->setLongitude($longitude);
55
56
        $this->assertEquals($longitude, $rdata->getLongitude());
57
        $this->assertEquals($longitude, $rdata->getLongitude(LOC::FORMAT_DECIMAL));
58
        $this->assertEquals($lon_dms, $rdata->getLongitude(LOC::FORMAT_DMS));
59
    }
60
61
    /**
62
     * @throws \OutOfRangeException