public function testSetYValue() { $matrixObject = new ECEF($this->_xyz); $fluidReturn = $matrixObject->setY($this->_distance); $matrixYValue = $matrixObject->getY(); $this->assertTrue(is_object($matrixYValue)); $this->assertTrue(is_a($matrixYValue, 'Geodetic\\Distance')); $this->assertEquals(12345.0, $matrixYValue->getValue()); // Test fluid return object $this->assertTrue(is_object($fluidReturn)); // ... of the correct type $this->assertTrue(is_a($fluidReturn, 'Geodetic\\ECEF')); }
public function testConvertFromWGS84() { $ecefObject = new ECEF($this->_xyz); $datum = new Datum(Datum::OSGB36); $ecefObject->fromWGS84($datum); $this->assertEquals(3805.0701543279, $ecefObject->getX()->getValue()); $this->assertEquals(-198.86566320382, $ecefObject->getY()->getValue()); $this->assertEquals(5097.7821917469, $ecefObject->getZ()->getValue()); }