Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test Mac OS X on Travis #130

Merged
merged 2 commits into from
Oct 23, 2017
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
18 changes: 18 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,30 @@ matrix:
include:
- php: 5.3
dist: precise
include:
- os: osx
language: generic
php: 7.0 # just to look right on travis
env:
- PACKAGE: php70
allow_failures:
- php: hhvm

sudo: false

install:
# OSX install inspired by https://github.com/kiler129/TravisCI-OSX-PHP
- |
if [[ "${TRAVIS_OS_NAME}" == "osx" ]]; then
brew tap homebrew/homebrew-php
echo "Installing PHP ..."
brew install "${PACKAGE}"
brew install "${PACKAGE}"-xdebug
brew link "${PACKAGE}"
echo "Installing composer ..."
curl -s http://getcomposer.org/installer | php
mv composer.phar /usr/local/bin/composer
fi
- COMPOSER_ROOT_VERSION=`git describe --abbrev=0` composer install --no-interaction

script:
Expand Down
4 changes: 4 additions & 0 deletions tests/FunctionalSecureServerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,10 @@ public function testEmitsErrorForConnectionWithPeerVerification()

public function testEmitsErrorIfConnectionIsCancelled()
{
if (PHP_OS !== 'Linux') {
$this->markTestSkipped('Linux only (OS is ' . PHP_OS . ')');
}

$loop = Factory::create();

$server = new TcpServer(0, $loop);
Expand Down
4 changes: 4 additions & 0 deletions tests/FunctionalTcpServerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,10 @@ public function testEmitsConnectionWithRemoteNullAddressAfterConnectionIsClosedL

public function testEmitsConnectionEvenIfConnectionIsCancelled()
{
if (PHP_OS !== 'Linux') {
$this->markTestSkipped('Linux only (OS is ' . PHP_OS . ')');
}

$loop = Factory::create();

$server = new TcpServer(0, $loop);
Expand Down