Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 6 additions & 16 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,25 +13,21 @@ branches:

env:
global:
- MIN_PHP=5.5.9
- MIN_PHP=7.0

matrix:
fast_finish: true
allow_failures:
- php: 5.5
- php: 7.0
env: deps="low"
include:
- php: 5.5
- php: 7.0
env: deps="low"
- php: 5.5
- php: 5.6
- php: 7.0
- php: 7.1
- php: hhvm

before_install:
- if [ "$TRAVIS_PHP_VERSION" != "hhvm" && "$TRAVIS_PHP_VERSION" != "7.0" ]; then pecl install geoip; fi
- if [ "$TRAVIS_PHP_VERSION" == "7.0" ]; then composer require "geoip/geoip"; fi
- composer require "geoip/geoip" --no-update
- |
# General configuration
stty cols 120
Expand All @@ -56,12 +52,8 @@ before_install:
COMPONENTS=$(find src -mindepth 2 -type f -name phpunit.xml.dist -printf '%h\n')

# php.ini configuration
if [[ $PHP = hhvm* ]]; then
INI=/etc/hhvm/php.ini
else
INI=~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
phpenv config-rm xdebug.ini || echo "xdebug not available"
fi
INI=~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
phpenv config-rm xdebug.ini || echo "xdebug not available"
echo memory_limit = -1 >> $INI

install:
Expand All @@ -78,8 +70,6 @@ install:
# Test the PhpUnit bridge on PHP 5.5, using the original phpunit script
tfold src/Symfony/Bridge/PhpUnit \
"cd src/Symfony/Bridge/PhpUnit && wget https://phar.phpunit.de/phpunit-4.8.phar && phpenv global 5.3 && composer update --no-progress --ansi && php phpunit-4.8.phar"
elif [[ $PHP = hhvm* ]]; then
$PHPUNIT --exclude-group benchmark,intl-data
else
echo "$COMPONENTS" | parallel --gnu "tfold {} $PHPUNIT_X {}"
tfold tty-group $PHPUNIT --group tty
Expand Down
7 changes: 3 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
}
],
"require": {
"php": "^5.5 || ^7.0",
"php": "^7.0",
"igorw/get-in": "^1.0",
"psr/http-message-implementation": "^1.0",
"php-http/client-implementation": "^1.0",
Expand All @@ -21,15 +21,14 @@
"php-http/discovery": "^1.0"
},
"require-dev": {
"phpunit/phpunit": "^4.8 || ^5.4",
"phpunit/phpunit": "^6.1",
"geocoder-php/provider-integration-tests": "dev-master",
"symfony/phpunit-bridge": "^3.2",
"geoip2/geoip2": "~2.0",
"symfony/stopwatch": "~2.5",
"php-http/message": "^1.0",
"php-http/curl-client": "^1.7",
"php-http/mock-client": "^1.0",
"guzzlehttp/psr7": "^1.4"
"nyholm/psr7": "^0.2.2"
},
"suggest": {
"ext-geoip": "Enabling the geoip extension allows you to use the MaxMindProvider.",
Expand Down
4 changes: 0 additions & 4 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,4 @@
</exclude>
</whitelist>
</filter>

<listeners>
<listener class="Symfony\Bridge\PhpUnit\SymfonyTestsListener" />
</listeners>
</phpunit>
3 changes: 2 additions & 1 deletion src/Common/Tests/Dumper/GeoArrayTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,12 @@

use Geocoder\Dumper\GeoArray;
use Geocoder\Model\LocationFactory;
use PHPUnit\Framework\TestCase;

/**
* @author Tomas Norkūnas <norkunas.tom@gmail.com>
*/
class GeoArrayTest extends \PHPUnit_Framework_TestCase
class GeoArrayTest extends TestCase
{
/**
* @var GeoArray
Expand Down
3 changes: 2 additions & 1 deletion src/Common/Tests/Dumper/GeoJsonTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,13 @@

use Geocoder\Dumper\GeoJson;
use Geocoder\Model\LocationFactory;
use PHPUnit\Framework\TestCase;

/**
* @author Jan Sorgalla <jsorgalla@googlemail.com>
* @author William Durand <william.durand1@gmail.com>
*/
class GeoJsonTest extends \PHPUnit_Framework_TestCase
class GeoJsonTest extends TestCase
{
/**
* @var GeoJson
Expand Down
3 changes: 2 additions & 1 deletion src/Common/Tests/Dumper/GpxTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,12 @@
use Geocoder\Geocoder;
use Geocoder\Dumper\Gpx;
use Geocoder\Model\LocationFactory;
use PHPUnit\Framework\TestCase;

/**
* @author William Durand <william.durand1@gmail.com>
*/
class GpxTest extends \PHPUnit_Framework_TestCase
class GpxTest extends TestCase
{
/**
* @var Gpx
Expand Down
3 changes: 2 additions & 1 deletion src/Common/Tests/Dumper/KmlTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,13 @@

use Geocoder\Dumper\Kml;
use Geocoder\Model\LocationFactory;
use PHPUnit\Framework\TestCase;

/**
* @author Jan Sorgalla <jsorgalla@googlemail.com>
* @author William Durand <william.durand1@gmail.com>
*/
class KmlTest extends \PHPUnit_Framework_TestCase
class KmlTest extends TestCase
{
/**
* @var Kml
Expand Down
3 changes: 2 additions & 1 deletion src/Common/Tests/Dumper/WkbTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,13 @@

use Geocoder\Dumper\Wkb;
use Geocoder\Model\LocationFactory;
use PHPUnit\Framework\TestCase;

/**
* @author Jan Sorgalla <jsorgalla@googlemail.com>
* @author William Durand <william.durand1@gmail.com>
*/
class WkbTest extends \PHPUnit_Framework_TestCase
class WkbTest extends TestCase
{
/**
* @var Wkb
Expand Down
3 changes: 2 additions & 1 deletion src/Common/Tests/Dumper/WktTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,13 @@

use Geocoder\Dumper\Wkt;
use Geocoder\Model\LocationFactory;
use PHPUnit\Framework\TestCase;

/**
* @author Jan Sorgalla <jsorgalla@googlemail.com>
* @author William Durand <william.durand1@gmail.com>
*/
class WktTest extends \PHPUnit_Framework_TestCase
class WktTest extends TestCase
{
/**
* @var Wkt
Expand Down
3 changes: 2 additions & 1 deletion src/Common/Tests/Formatter/StringFormatterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,12 @@

use Geocoder\Formatter\StringFormatter;
use Geocoder\Model\LocationFactory;
use PHPUnit\Framework\TestCase;

/**
* @author William Durand <william.durand1@gmail.com>
*/
class StringFormatterTest extends \PHPUnit_Framework_TestCase
class StringFormatterTest extends TestCase
{
/**
* @var StringFormatter
Expand Down
3 changes: 2 additions & 1 deletion src/Common/Tests/Model/AddressCollectionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,12 @@
namespace Geocoder\Tests\Model;

use Geocoder\Model\AddressCollection;
use PHPUnit\Framework\TestCase;

/**
* @author Tobias Nyholm <tobias.nyholm@gmail.com>
*/
class AddressCollectionTest extends \PHPUnit_Framework_TestCase
class AddressCollectionTest extends TestCase
{
/**
* @expectedException \Geocoder\Exception\CollectionIsEmpty
Expand Down
3 changes: 2 additions & 1 deletion src/Common/Tests/Model/AddressTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,12 @@

use Geocoder\Model\Address;
use Geocoder\Model\LocationFactory;
use PHPUnit\Framework\TestCase;

/**
* @author Antoine Lemaire <lemaireantoine@hotmail.com>
*/
class AddressTest extends \PHPUnit_Framework_TestCase
class AddressTest extends TestCase
{
public function testDumpEmptyAddress()
{
Expand Down
3 changes: 2 additions & 1 deletion src/Common/Tests/Model/LocationFactoryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,13 @@
use Geocoder\Model\AddressCollection;
use Geocoder\Model\LocationFactory;
use Geocoder\Location;
use PHPUnit\Framework\TestCase;

/**
* @author Antoine Corcy <contact@sbin.dk>
* @author William Durand <william.durand1@gmail.com>
*/
class LocationFactoryTest extends \PHPUnit_Framework_TestCase
class LocationFactoryTest extends TestCase
{
public function testCreateFromArray()
{
Expand Down
3 changes: 2 additions & 1 deletion src/Common/Tests/ProviderAggregatorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,12 @@
use Geocoder\ProviderAggregator;
use Geocoder\Provider\LocaleAwareGeocoder;
use Geocoder\Provider\Provider;
use PHPUnit\Framework\TestCase;

/**
* @author William Durand <william.durand1@gmail.com>
*/
class ProviderAggregatorTest extends \PHPUnit_Framework_TestCase
class ProviderAggregatorTest extends TestCase
{
/**
* @var TestableGeocoder
Expand Down
3 changes: 2 additions & 1 deletion src/Common/Tests/TimedGeocoderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,10 @@

use Geocoder\Provider\Provider;
use Geocoder\TimedGeocoder;
use PHPUnit\Framework\TestCase;
use Symfony\Component\Stopwatch\Stopwatch;

class TimedGeocoderTest extends \PHPUnit_Framework_TestCase
class TimedGeocoderTest extends TestCase
{
/**
* @var Stopwatch
Expand Down
6 changes: 3 additions & 3 deletions src/Common/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
}
],
"require": {
"php": "^5.5 || ^7.0",
"php": "^7.0",
"igorw/get-in": "^1.0",
"psr/http-message-implementation": "^1.0",
"php-http/client-implementation": "^1.0",
Expand All @@ -21,12 +21,12 @@
"php-http/discovery": "^1.0"
},
"require-dev": {
"phpunit/phpunit": "^4.8",
"phpunit/phpunit": "^6.1",
"symfony/stopwatch": "~2.5",
"php-http/message": "^1.0",
"php-http/curl-client": "^1.7",
"php-http/mock-client": "^0.3.0",
"guzzlehttp/psr7": "^1.4"
"nyholm/psr7": "^0.2.2"
},
"suggest": {
"symfony/stopwatch": "If you want to use the TimedGeocoder"
Expand Down
4 changes: 2 additions & 2 deletions src/Provider/ArcGISOnline/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
}
],
"require": {
"php": "^5.5 || ^7.0",
"php": "^7.0",
"willdurand/geocoder": "^4.0"
},
"require-dev": {
"phpunit/phpunit": "^4.8",
"php-http/message": "^1.0",
"php-http/curl-client": "^1.7",
"symfony/phpunit-bridge": "^3.2",
"guzzlehttp/psr7": "^1.4"
"nyholm/psr7": "^0.2.2"
},
"autoload": {
"psr-4": { "Geocoder\\Provider\\ArcGISOnine\\": "" },
Expand Down
4 changes: 2 additions & 2 deletions src/Provider/BingMaps/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
}
],
"require": {
"php": "^5.5 || ^7.0",
"php": "^7.0",
"willdurand/geocoder": "^4.0"
},
"require-dev": {
"phpunit/phpunit": "^4.8",
"php-http/message": "^1.0",
"php-http/curl-client": "^1.7",
"symfony/phpunit-bridge": "^3.2",
"guzzlehttp/psr7": "^1.4"
"nyholm/psr7": "^0.2.2"
},
"autoload": {
"psr-4": { "Geocoder\\Provider\\BingMaps\\": "" },
Expand Down
4 changes: 2 additions & 2 deletions src/Provider/Chain/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
}
],
"require": {
"php": "^5.5 || ^7.0",
"php": "^7.0",
"willdurand/geocoder": "^4.0"
},
"require-dev": {
"phpunit/phpunit": "^4.8",
"php-http/message": "^1.0",
"php-http/curl-client": "^1.7",
"symfony/phpunit-bridge": "^3.2",
"guzzlehttp/psr7": "^1.4"
"nyholm/psr7": "^0.2.2"
},
"autoload": {
"psr-4": { "Geocoder\\Provider\\Chain\\": "" },
Expand Down
4 changes: 2 additions & 2 deletions src/Provider/FreeGeoIp/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
}
],
"require": {
"php": "^5.5 || ^7.0",
"php": "^7.0",
"willdurand/geocoder": "^4.0"
},
"require-dev": {
"phpunit/phpunit": "^4.8",
"php-http/message": "^1.0",
"php-http/curl-client": "^1.7",
"symfony/phpunit-bridge": "^3.2",
"guzzlehttp/psr7": "^1.4"
"nyholm/psr7": "^0.2.2"
},
"autoload": {
"psr-4": { "Geocoder\\Provider\\FreeGeoIp\\": "" },
Expand Down
4 changes: 2 additions & 2 deletions src/Provider/GeoIP2/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
}
],
"require": {
"php": "^5.5 || ^7.0",
"php": "^7.0",
"willdurand/geocoder": "^4.0"
},
"require-dev": {
"phpunit/phpunit": "^4.8",
"php-http/message": "^1.0",
"php-http/curl-client": "^1.7",
"symfony/phpunit-bridge": "^3.2",
"guzzlehttp/psr7": "^1.4"
"nyholm/psr7": "^0.2.2"
},
"autoload": {
"psr-4": { "Geocoder\\Provider\\GeoIP2\\": "" },
Expand Down
4 changes: 2 additions & 2 deletions src/Provider/GeoIPs/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
}
],
"require": {
"php": "^5.5 || ^7.0",
"php": "^7.0",
"willdurand/geocoder": "^4.0"
},
"require-dev": {
"phpunit/phpunit": "^4.8",
"php-http/message": "^1.0",
"php-http/curl-client": "^1.7",
"symfony/phpunit-bridge": "^3.2",
"guzzlehttp/psr7": "^1.4"
"nyholm/psr7": "^0.2.2"
},
"autoload": {
"psr-4": { "Geocoder\\Provider\\GeoIPs\\": "" },
Expand Down
Loading