From bd05c590e3e9eca5d5a420f6b68a905d7518ff7c Mon Sep 17 00:00:00 2001 From: Adrien Crivelli Date: Thu, 26 Nov 2020 11:10:52 +0900 Subject: [PATCH] Drop Travis --- .gitattributes | 1 - .github/workflows/main.yml | 2 +- .travis.yml | 34 ------------------- README.md | 2 +- .../PhpSpreadsheetTests/Helper/SampleTest.php | 2 +- .../Reader/Xml/XmlLoadTest.php | 7 +--- 6 files changed, 4 insertions(+), 44 deletions(-) delete mode 100644 .travis.yml diff --git a/.gitattributes b/.gitattributes index 0186deae..19c90f40 100644 --- a/.gitattributes +++ b/.gitattributes @@ -5,7 +5,6 @@ /.php_cs.dist export-ignore /.sami.php export-ignore /.scrutinizer.yml export-ignore -/.travis.yml export-ignore /CHANGELOG.PHPExcel.md export-ignore /bin export-ignore /composer.lock export-ignore diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 88168fa0..febc244b 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,4 +1,4 @@ -name: Build +name: main on: [ push, pull_request ] jobs: test: diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 6eb59290..00000000 --- a/.travis.yml +++ /dev/null @@ -1,34 +0,0 @@ -language: php -dist: bionic - -php: - - 7.2 - - 7.3 - - 7.4 - - nightly - -cache: - directories: - - vendor - - $HOME/.composer/cache - -before_script: - # Deactivate xdebug - - if [[ $TRAVIS_PHP_VERSION != nightly ]]; then phpenv config-rm xdebug.ini; fi - - if [[ $TRAVIS_PHP_VERSION == nightly ]]; then rm composer.lock; fi - - composer install --ignore-platform-reqs - -script: - - ./vendor/bin/phpunit --color=always --coverage-text - -allow_failures: - - php: nightly - -jobs: - include: - - - stage: Code style - php: 7.4 - script: - - ./vendor/bin/php-cs-fixer fix --diff --verbose --dry-run - - ./vendor/bin/phpcs diff --git a/README.md b/README.md index 0cef8326..2a94e0d3 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # PhpSpreadsheet -[![Build Status](https://travis-ci.org/PHPOffice/PhpSpreadsheet.svg?branch=master)](https://travis-ci.org/PHPOffice/PhpSpreadsheet) +[![Build Status](https://github.com/PHPOffice/PhpSpreadsheet/workflows/main/badge.svg)](https://github.com/PHPOffice/PhpSpreadsheet/actions) [![Code Quality](https://scrutinizer-ci.com/g/PHPOffice/PhpSpreadsheet/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/PHPOffice/PhpSpreadsheet/?branch=master) [![Code Coverage](https://scrutinizer-ci.com/g/PHPOffice/PhpSpreadsheet/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/PHPOffice/PhpSpreadsheet/?branch=master) [![Total Downloads](https://img.shields.io/packagist/dt/PHPOffice/PhpSpreadsheet)](https://packagist.org/packages/phpoffice/phpspreadsheet) diff --git a/tests/PhpSpreadsheetTests/Helper/SampleTest.php b/tests/PhpSpreadsheetTests/Helper/SampleTest.php index 369b205e..8fd6bb47 100644 --- a/tests/PhpSpreadsheetTests/Helper/SampleTest.php +++ b/tests/PhpSpreadsheetTests/Helper/SampleTest.php @@ -43,7 +43,7 @@ class SampleTest extends TestCase } // Unfortunately some tests are too long be ran with code-coverage - // analysis on Travis, so we need to exclude them + // analysis on GitHub Actions, so we need to exclude them global $argv; if (in_array('--coverage-clover', $argv)) { $tooLongToBeCovered = [ diff --git a/tests/PhpSpreadsheetTests/Reader/Xml/XmlLoadTest.php b/tests/PhpSpreadsheetTests/Reader/Xml/XmlLoadTest.php index 03f977f5..969571f2 100644 --- a/tests/PhpSpreadsheetTests/Reader/Xml/XmlLoadTest.php +++ b/tests/PhpSpreadsheetTests/Reader/Xml/XmlLoadTest.php @@ -82,14 +82,9 @@ class XmlLoadTest extends TestCase public function testLoadUnusableSample(): void { // Sample spreadsheet is not readable by Excel. - // But PhpSpreadsheet can load it except for coverage test. - //global $argv; - //if (in_array('--coverage-clover', $argv)) { - // self::markTestSkipped('Mysterious Travis coverage failure IOFactoryTest'); - //} + // But PhpSpreadsheet can load it. $filename = __DIR__ . '/../../../..' - //. '/samples/templates/Excel2003XMLTest.xml'; . '/samples/templates/excel2003.short.bad.xml'; $reader = new Xml(); $spreadsheet = $reader->load($filename);