From 9e185310b8b4a576f44f05811db72855b4c3a2ff Mon Sep 17 00:00:00 2001 From: Nick Sagona Date: Thu, 11 Feb 2021 23:01:22 -0600 Subject: [PATCH] Update version and copyright --- .gitattributes | 1 - .github/workflows/phpunit.yml | 37 +++++++++++++++++++++++++++++++++++ .travis.yml | 13 ------------ LICENSE.TXT | 2 +- README.md | 2 +- composer.json | 9 ++++++--- phpunit.xml | 31 ++++++++++++++--------------- src/AbstractPaginator.php | 6 +++--- src/Exception.php | 6 +++--- src/Form.php | 6 +++--- src/Paginator.php | 6 +++--- src/Range.php | 6 +++--- tests/PaginatorTest.php | 2 +- 13 files changed, 76 insertions(+), 51 deletions(-) create mode 100644 .github/workflows/phpunit.yml delete mode 100644 .travis.yml diff --git a/.gitattributes b/.gitattributes index 3c5830d..03bf387 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,3 +1,2 @@ tests/ export-ignore phpunit.xml export-ignore -.travis.yml export-ignore diff --git a/.github/workflows/phpunit.yml b/.github/workflows/phpunit.yml new file mode 100644 index 0000000..c01359a --- /dev/null +++ b/.github/workflows/phpunit.yml @@ -0,0 +1,37 @@ +name: phpunit + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + + #- name: Validate composer.json and composer.lock + # run: composer validate + + - name: Cache Composer packages + id: composer-cache + uses: actions/cache@v2 + with: + path: vendor + key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }} + restore-keys: | + ${{ runner.os }}-php- + + - name: Install dependencies + if: steps.composer-cache.outputs.cache-hit != 'true' + run: composer install --prefer-dist --no-progress --no-suggest + + # Add a test script to composer.json, for instance: "test": "vendor/bin/phpunit" + # Docs: https://getcomposer.org/doc/articles/scripts.md + + - name: Run test suite + run: composer run-script test diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index b040dc0..0000000 --- a/.travis.yml +++ /dev/null @@ -1,13 +0,0 @@ -before_script: - - composer self-update - - composer install -language: php -branches: - only: - - master -php: - - 7.1 -script: - - ./vendor/bin/phpunit -notifications: - email: false diff --git a/LICENSE.TXT b/LICENSE.TXT index 191f9e9..b20d09a 100644 --- a/LICENSE.TXT +++ b/LICENSE.TXT @@ -1,6 +1,6 @@ BSD 3 Clause License -Copyright (c) 2009-2020, NOLA Interactive, LLC. +Copyright (c) 2009-2021, NOLA Interactive, LLC. All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/README.md b/README.md index 082179e..3282da8 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ pop-paginator ============= -[![Build Status](https://travis-ci.org/popphp/pop-paginator.svg?branch=master)](https://travis-ci.org/popphp/pop-paginator) +[![Build Status](https://github.com/popphp/pop-paginator/workflows/phpunit/badge.svg)](https://github.com/popphp/pop-paginator/actions) [![Coverage Status](http://cc.popphp.org/coverage.php?comp=pop-paginator)](http://cc.popphp.org/pop-paginator/) OVERVIEW diff --git a/composer.json b/composer.json index 3a5ac84..c78f076 100644 --- a/composer.json +++ b/composer.json @@ -18,10 +18,10 @@ } ], "require": { - "php": ">=7.1.0" + "php": ">=7.3.0" }, "require-dev": { - "phpunit/phpunit": "^7.0.0" + "phpunit/phpunit": "^9.0.0" }, "autoload": { "psr-4": { @@ -33,9 +33,12 @@ "Pop\\Paginator\\Test\\": "tests/" } }, + "scripts": { + "test": "vendor/bin/phpunit" + }, "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "3.1.x-dev" } } } diff --git a/phpunit.xml b/phpunit.xml index f781aba..437ae3a 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -1,18 +1,17 @@ - - - - tests - - - - - src - - - - - - + + + + src + + + + + + + + tests + + + diff --git a/src/AbstractPaginator.php b/src/AbstractPaginator.php index 40eea2d..930ca08 100644 --- a/src/AbstractPaginator.php +++ b/src/AbstractPaginator.php @@ -4,7 +4,7 @@ * * @link https://github.com/popphp/popphp-framework * @author Nick Sagona, III - * @copyright Copyright (c) 2009-2020 NOLA Interactive, LLC. (http://www.nolainteractive.com) + * @copyright Copyright (c) 2009-2021 NOLA Interactive, LLC. (http://www.nolainteractive.com) * @license http://www.popphp.org/license New BSD License */ @@ -19,9 +19,9 @@ * @category Pop * @package Pop\Paginator * @author Nick Sagona, III - * @copyright Copyright (c) 2009-2020 NOLA Interactive, LLC. (http://www.nolainteractive.com) + * @copyright Copyright (c) 2009-2021 NOLA Interactive, LLC. (http://www.nolainteractive.com) * @license http://www.popphp.org/license New BSD License - * @version 3.0.5 + * @version 3.1.0 */ abstract class AbstractPaginator { diff --git a/src/Exception.php b/src/Exception.php index 2875fac..d5c9599 100644 --- a/src/Exception.php +++ b/src/Exception.php @@ -4,7 +4,7 @@ * * @link https://github.com/popphp/popphp-framework * @author Nick Sagona, III - * @copyright Copyright (c) 2009-2020 NOLA Interactive, LLC. (http://www.nolainteractive.com) + * @copyright Copyright (c) 2009-2021 NOLA Interactive, LLC. (http://www.nolainteractive.com) * @license http://www.popphp.org/license New BSD License */ @@ -19,8 +19,8 @@ * @category Pop * @package Pop\Paginator * @author Nick Sagona, III - * @copyright Copyright (c) 2009-2020 NOLA Interactive, LLC. (http://www.nolainteractive.com) + * @copyright Copyright (c) 2009-2021 NOLA Interactive, LLC. (http://www.nolainteractive.com) * @license http://www.popphp.org/license New BSD License - * @version 3.0.5 + * @version 3.1.0 */ class Exception extends \Exception {} diff --git a/src/Form.php b/src/Form.php index c15bc31..6c1e18d 100644 --- a/src/Form.php +++ b/src/Form.php @@ -4,7 +4,7 @@ * * @link https://github.com/popphp/popphp-framework * @author Nick Sagona, III - * @copyright Copyright (c) 2009-2020 NOLA Interactive, LLC. (http://www.nolainteractive.com) + * @copyright Copyright (c) 2009-2021 NOLA Interactive, LLC. (http://www.nolainteractive.com) * @license http://www.popphp.org/license New BSD License */ @@ -19,9 +19,9 @@ * @category Pop * @package Pop\Paginator * @author Nick Sagona, III - * @copyright Copyright (c) 2009-2020 NOLA Interactive, LLC. (http://www.nolainteractive.com) + * @copyright Copyright (c) 2009-2021 NOLA Interactive, LLC. (http://www.nolainteractive.com) * @license http://www.popphp.org/license New BSD License - * @version 3.0.5 + * @version 3.1.0 */ class Form extends AbstractPaginator { diff --git a/src/Paginator.php b/src/Paginator.php index aea4d01..331a59c 100644 --- a/src/Paginator.php +++ b/src/Paginator.php @@ -4,7 +4,7 @@ * * @link https://github.com/popphp/popphp-framework * @author Nick Sagona, III - * @copyright Copyright (c) 2009-2020 NOLA Interactive, LLC. (http://www.nolainteractive.com) + * @copyright Copyright (c) 2009-2021 NOLA Interactive, LLC. (http://www.nolainteractive.com) * @license http://www.popphp.org/license New BSD License */ @@ -19,9 +19,9 @@ * @category Pop * @package Pop\Paginator * @author Nick Sagona, III - * @copyright Copyright (c) 2009-2020 NOLA Interactive, LLC. (http://www.nolainteractive.com) + * @copyright Copyright (c) 2009-2021 NOLA Interactive, LLC. (http://www.nolainteractive.com) * @license http://www.popphp.org/license New BSD License - * @version 3.0.5 + * @version 3.1.0 */ class Paginator { diff --git a/src/Range.php b/src/Range.php index c49d3ee..bff9145 100644 --- a/src/Range.php +++ b/src/Range.php @@ -4,7 +4,7 @@ * * @link https://github.com/popphp/popphp-framework * @author Nick Sagona, III - * @copyright Copyright (c) 2009-2020 NOLA Interactive, LLC. (http://www.nolainteractive.com) + * @copyright Copyright (c) 2009-2021 NOLA Interactive, LLC. (http://www.nolainteractive.com) * @license http://www.popphp.org/license New BSD License */ @@ -19,9 +19,9 @@ * @category Pop * @package Pop\Paginator * @author Nick Sagona, III - * @copyright Copyright (c) 2009-2020 NOLA Interactive, LLC. (http://www.nolainteractive.com) + * @copyright Copyright (c) 2009-2021 NOLA Interactive, LLC. (http://www.nolainteractive.com) * @license http://www.popphp.org/license New BSD License - * @version 3.0.5 + * @version 3.1.0 */ class Range extends AbstractPaginator { diff --git a/tests/PaginatorTest.php b/tests/PaginatorTest.php index 50c20e1..f849bb7 100644 --- a/tests/PaginatorTest.php +++ b/tests/PaginatorTest.php @@ -98,7 +98,7 @@ public function testGetForm() $pages = (string)$paginator; $this->assertEquals(' o ', $paginator->getInputSeparator()); $this->assertEquals(13, $paginator->getNumberOfPages()); - $this->assertContains('assertStringContainsString('