Skip to content

Commit

Permalink
[Tests] Rely on the new library cache system (#212)
Browse files Browse the repository at this point in the history
  • Loading branch information
GeLoLabs committed May 27, 2017
1 parent de44267 commit 7bf61dd
Show file tree
Hide file tree
Showing 29 changed files with 21 additions and 8 deletions.
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ php:
- 7.1
- hhvm

dist: trusty

branches:
only: master

Expand Down
Binary file added Tests/.cache/-/6/eOVICXPxdutNXHow1GQW
Binary file not shown.
Binary file added Tests/.cache/4/L/4l5x4IBHGaCTaz-pOxbI
Binary file not shown.
Binary file added Tests/.cache/6/Y/HvUKmUNJ-sn--mK-kiwb
Binary file not shown.
Binary file added Tests/.cache/8/F/q6vDVpHMAKQKudk5AVvf
Binary file not shown.
Binary file added Tests/.cache/8/N/l+Beu6bTdNtstpNhrShe
Binary file not shown.
Binary file added Tests/.cache/9/3/T0UhcBzXT5-mc4rTMHtg
Binary file not shown.
Binary file added Tests/.cache/D/B/P26siEGrVmmP6uJN7CNT
Binary file not shown.
Binary file added Tests/.cache/E/O/EEKLfKV5f6P3Tw36oLwW
Binary file not shown.
Binary file added Tests/.cache/F/Y/zG+eEMTpmmNSiZqU6VY9
Binary file not shown.
Binary file added Tests/.cache/H/V/tJcDMEEcxETAJbcaor0v
Binary file not shown.
Binary file added Tests/.cache/I/B/OhN+C1MSYhT54DiipGEU
Binary file not shown.
Binary file added Tests/.cache/J/-/WSf9XX1PnKs4k4B87DL-
Binary file not shown.
Binary file added Tests/.cache/K/6/3JZNgY9EsG41HesW4Dd+
Binary file not shown.
Binary file added Tests/.cache/K/T/LuEKSXutvU2RAjClXdGp
Binary file not shown.
Binary file added Tests/.cache/M/X/m-qdXisCX3tSXC0YBMq0
Binary file not shown.
Binary file added Tests/.cache/N/S/mSFWdEGYV7vtkTKJ7AJp
Binary file not shown.
Binary file added Tests/.cache/O/K/YKVYFYS0F9tUgEHl+866
Binary file not shown.
Binary file added Tests/.cache/Q/S/BODtMci3fW4rCnvwuFh2
Binary file not shown.
Binary file added Tests/.cache/V/L/p0HNdxtsXRWaANlim5vX
Binary file not shown.
Binary file added Tests/.cache/W/T/dYsDwPULlx1WrIut8Z5R
Binary file not shown.
Binary file added Tests/.cache/W/T/rW2QoPXYECnybWoOQnn9
Binary file not shown.
Binary file added Tests/.cache/X/-/lth79u5gGduZBIba8F3L
Binary file not shown.
Binary file added Tests/.cache/Z/-/XKSIw6zElLM5zUKQbuaJ
Binary file not shown.
8 changes: 8 additions & 0 deletions Tests/autoload.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,14 @@
* file that was distributed with this source code.
*/

if (isset($_SERVER['CACHE_PATH'])) {
$_SERVER['CACHE_PATH'] = __DIR__.'/../'.$_SERVER['CACHE_PATH'];

if (isset($_SERVER['CACHE_RESET']) && $_SERVER['CACHE_RESET']) {
exec('rm -rf '.$_SERVER['CACHE_PATH'].'/*');
}
}

require_once __DIR__.'/../vendor/autoload.php';

\PHPUnit_Extensions_Selenium2TestCase::shareSession(true);
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@
"require": {
"php": "^5.6|^7.0",
"symfony/framework-bundle": "^2.7|^3.0",
"egeloen/google-map": "^2.0"
"egeloen/google-map": "^2.0.2"
},
"require-dev": {
"egeloen/serializer-bundle": "^1.0",
"friendsofphp/php-cs-fixer": "^2.0",
"php-http/cache-plugin": "^1.2",
"php-http/cache-plugin": "^1.4",
"php-http/guzzle6-adapter": "^1.0",
"phpunit/phpunit": "^5.4",
"phpunit/phpunit-selenium": "dev-master",
Expand Down
5 changes: 3 additions & 2 deletions phpunit.ci.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@
</testsuite>
</testsuites>
<php>
<server name="API_KEY" value="AIzaSyDKaDeZ6PvKb3RqgIaFeKSSdVRtLc9jM1I" />
<server name="API_SECRET" value="zKAvb7nwW1TnJZtfXWC9Y_uUDU4" />
<server name="API_KEY" value="AIzaSyAbfXoOk_L4Ryk6aFvdqeAJvbg1ShYiqAE" />
<server name="API_SECRET" value="78BBhyDNOeFG_PWqHi6XUJ3woJE=" />
<server name="BROWSER_NAME" value="chrome" />
<server name="CACHE_PATH" value="Tests/.cache" />
</php>
<filter>
<whitelist>
Expand Down
6 changes: 4 additions & 2 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@
</testsuite>
</testsuites>
<php>
<server name="API_KEY" value="AIzaSyDKaDeZ6PvKb3RqgIaFeKSSdVRtLc9jM1I" />
<server name="API_SECRET" value="zKAvb7nwW1TnJZtfXWC9Y_uUDU4" />
<server name="API_KEY" value="AIzaSyAbfXoOk_L4Ryk6aFvdqeAJvbg1ShYiqAE" />
<server name="API_SECRET" value="78BBhyDNOeFG_PWqHi6XUJ3woJE=" />
<server name="BROWSER_NAME" value="chrome" />
<server name="SELENIUM_HOST" value="selenium" />
<server name="CACHE_PATH" value="Tests/.cache" />
<server name="CACHE_RESET" value="false" />
</php>
<filter>
<whitelist>
Expand Down
4 changes: 2 additions & 2 deletions travis/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ fi
export DISPLAY=:99
/sbin/start-stop-daemon -Sbmq -p /tmp/xvfb_99.pid -x /usr/bin/Xvfb -- ${DISPLAY} -ac -screen 0, 1600x1200x24

curl http://selenium-release.storage.googleapis.com/2.48/selenium-server-standalone-2.48.0.jar > selenium.jar
curl http://chromedriver.storage.googleapis.com/2.12/chromedriver_linux64.zip > chromedriver.zip
curl https://selenium-release.storage.googleapis.com/2.53/selenium-server-standalone-2.53.1.jar > selenium.jar
curl https://chromedriver.storage.googleapis.com/2.25/chromedriver_linux64.zip > chromedriver.zip
unzip chromedriver.zip

java -jar selenium.jar -Dwebdriver.chrome.driver=./chromedriver > /dev/null 2>&1 &
Expand Down

0 comments on commit 7bf61dd

Please sign in to comment.