ci: add newer PHP versions

Seems I had started this a while back and never actually finished.
Bumped the copyright years and added a funding and git ignore file.
Redid the Travis configuration based on my more recent experiences with
testing multiple PHP versions. Updated the development dependencies and
added a configuration file for PHPUnit.
This commit is contained in:
Josh Sherman 2020-01-26 17:23:06 -06:00
parent 805b303a04
commit 90ba4df308
No known key found for this signature in database
GPG key ID: 55B058A80530EF22
6 changed files with 76 additions and 41 deletions

4
.gitignore vendored Normal file
View file

@ -0,0 +1,4 @@
composer.lock
composer.phar
.phpunit.result.cache
/vendor/

View file

@ -1,5 +1,5 @@
language: php
dist: trusty
dist: bionic
sudo: required
matrix:
@ -7,26 +7,34 @@ matrix:
- php: 5.3
dist: precise
- php: 5.4
dist: trusty
- php: 5.5
dist: trusty
- php: 5.6
dist: trusty
- php: 7.0
dist: xenial
- php: 7.1
- php: 7.2
- php: hhvm
env: HHVM=true
- php: 7.3
- php: 7.4
env: COVERAGE=true
- php: nightly
allow_failures:
- php: nightly
install:
- php --version
- composer install
- if [[ $HHVM == true ]]; then composer require "phpunit/phpunit:5.7"; fi
before_script:
- mkdir -p build/logs
- cd tests
script:
- if [[ $HHVM == true ]]; then ../vendor/bin/phpunit --colors --coverage-clover ../build/logs/clover.xml .; fi
- if [[ $HHVM != true ]]; then phpunit --colors --coverage-clover ../build/logs/clover.xml .; fi
- vendor/bin/phpunit --coverage-clover build/logs/clover.xml
after_success:
- cd ..
- php vendor/bin/coveralls --config .coveralls.yml -v
- |
if [[ $COVERAGE ]]; then
travis_retry php vendor/bin/php-coveralls --config .coveralls.yml -v
fi

1
FUNDING.yml Normal file
View file

@ -0,0 +1 @@
patreon: joshtronic

View file

@ -1,6 +1,6 @@
The MIT License (MIT)
Copyright (c) 2012, 2013, 2014, 2015, 2016, 2017, 2018 Josh Sherman
Copyright (c) 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Josh Sherman
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in

View file

@ -13,18 +13,17 @@
],
"homepage": "https://github.com/joshtronic/php-projecthoneypot",
"license": "MIT",
"authors": [
{
"authors": [{
"name": "Josh Sherman",
"email": "hello@joshtronic.com",
"homepage": "https://joshtronic.com"
}
],
"require-dev": {
"php": ">=5.3.0"
}],
"require": {
"php": ">=5.3"
},
"require-dev": {
"satooshi/php-coveralls": "~1.0"
"php-coveralls/php-coveralls": ">=1",
"phpunit/phpunit": ">=4"
},
"autoload": {
"psr-4": {

23
phpunit.xml Normal file
View file

@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
failOnRisky="true"
stopOnError="true"
stopOnFailure="true"
stopOnIncomplete="true"
verbose="true"
>
<testsuites>
<testsuite name="Project Honey Pot">
<directory>tests</directory>
</testsuite>
</testsuites>
<filter>
<whitelist addUncoveredFilesFromWhitelist="true">
<directory>./src</directory>
</whitelist>
</filter>
</phpunit>