public function testBySupportEMV() { $options = new AtmLocationRequestOptions(0, 25); $options->setSupportEmv(AtmLocationRequestOptions::SUPPORT_EMV_YES); $options->setLatitude(1.2833); $options->setLongitude(103.8499); $atms = $this->service->getAtms($options); $this->assertTrue(count($atms->getAtm()) > 0); }
private function getURL(AtmLocationRequestOptions $options) { $url = ""; if ($this->environment == Environment::PRODUCTION) { $url = $this->PRODUCTION_URL; } else { $url = $this->SANDBOX_URL; } $url = URLUtil::addQueryParameter($url, "PageLength", $options->getPageLength()); $url = URLUtil::addQueryParameter($url, "PageOffset", $options->getPageOffset()); $url = URLUtil::addQueryParameter($url, "AddressLine1", $options->getAddressLine1()); $url = URLUtil::addQueryParameter($url, "AddressLine2", $options->getAddressLine2()); $url = URLUtil::addQueryParameter($url, "City", $options->getCity()); $url = URLUtil::addQueryParameter($url, "CountrySubdivision", $options->getCountrySubdivision()); $url = URLUtil::addQueryParameter($url, "PostalCode", $options->getPostalCode()); $url = URLUtil::addQueryParameter($url, "Country", $options->getCountry()); $url = URLUtil::addQueryParameter($url, "Latitude", $options->getLatitude()); $url = URLUtil::addQueryParameter($url, "Longitude", $options->getLongitude()); $url = URLUtil::addQueryParameter($url, "DistanceUnit", $options->getDistanceUnit()); $url = URLUtil::addQueryParameter($url, "Radius", $options->getRadius()); $url = URLUtil::addQueryParameter($url, "SupportEMV", $options->getSupportEmv()); return $url; }