Skip to content

Instantly share code, notes, and snippets.

@selfthinker
Last active March 18, 2018 23:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save selfthinker/fb7fc750f1f2ad3a92a46abe2dbf6f06 to your computer and use it in GitHub Desktop.
Save selfthinker/fb7fc750f1f2ad3a92a46abe2dbf6f06 to your computer and use it in GitHub Desktop.
Trying to fix .travis.yml for DokuWiki plugins
language: php
php:
- "7.2"
- "7.1"
- "7.0"
- "5.6"
env:
- DOKUWIKI=master
- DOKUWIKI=stable
- DOKUWIKI=old-stable
before_install: wget https://raw.github.com/splitbrain/dokuwiki-travis/master/travis.sh
install: sh travis.sh
script: cd _test && phpunit --stderr --group plugin_wrap
language: php
php:
- "7.2"
- "7.1"
- "7.0"
- "5.6"
env:
- DOKUWIKI=master
- DOKUWIKI=stable
- DOKUWIKI=old-stable
before_install: wget https://raw.github.com/splitbrain/dokuwiki-travis/master/travis.sh
install: sh travis.sh
before_script:
- wget https://phar.phpunit.de/phpunit-5.7.phar
- cd _test
script:
- if [ "$DOKUWIKI" = "master" ]; then phpunit --stderr --group plugin_wrap; fi
- if [ "$DOKUWIKI" != "master" ]; then php ../phpunit-5.7.phar --stderr --group plugin_wrap; fi
language: php
php:
- "7.2"
- "7.1"
- "7.0"
- "5.6"
env:
- DOKUWIKI=master PHPUNIT_VERSION=phpunit
- DOKUWIKI=stable PHPUNIT_VERSION="php ../phpunit-5.7.phar"
- DOKUWIKI=old-stable PHPUNIT_VERSION="php ../phpunit-5.7.phar"
before_install: wget https://raw.github.com/splitbrain/dokuwiki-travis/master/travis.sh
install: sh travis.sh
before_script:
- wget https://phar.phpunit.de/phpunit-5.7.phar
- cd _test
script: $PHPUNIT_VERSION --stderr --group plugin_wrap
@selfthinker
Copy link
Author

selfthinker commented Mar 18, 2018

Both new travis files currently fail all non-master DokuWiki branches with

Could not open input file: ../phpunit-5.7.phar

I tried to also change permissions in before_install but that didn't work either:

   - chmod 755 phpunit-5.7.phar
(or)
   - chmod +x phpunit-5.7.phar

@selfthinker
Copy link
Author

It's fixed now. The wget of PHPUnit needed to be in before_script and not before_install.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment