diff options
author | korelstar <korelstar@users.noreply.github.com> | 2020-06-19 16:01:42 +0300 |
---|---|---|
committer | korelstar <korelstar@users.noreply.github.com> | 2020-06-19 23:09:56 +0300 |
commit | 8c83ac2129a30acb986c472dc4ce23de10c1313c (patch) | |
tree | 78e00ef905e6aa8bcc1092066e3c23f91d14bcc2 /.github | |
parent | e677f619f0bf3f770790ff306f20108befd6c9bd (diff) |
declare supported PHP versions and re-adjust tests
Diffstat (limited to '.github')
-rw-r--r-- | .github/workflows/lint.yml | 13 | ||||
-rw-r--r-- | .github/workflows/test.yml | 15 |
2 files changed, 13 insertions, 15 deletions
diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index a5218712..d0934734 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -46,18 +46,17 @@ jobs: strategy: matrix: version: [min, max] - include: - - version: min - php-version: 7.1 - - version: max - php-version: 7.4 steps: - name: Checkout uses: actions/checkout@v2 - - name: Set up php${{ matrix.php-versions }} + - name: Determine PHP version + env: + VERSION_MINMAX: ${{ matrix.version }} + run: echo "::set-env name=PHP_VERSION::$(php tests/nextcloud-version.php --php-$VERSION_MINMAX)" + - name: Set up PHP ${{ env.PHP_VERSION }} uses: shivammathur/setup-php@v2 with: - php-version: ${{ matrix.php-version }} + php-version: ${{ env.PHP_VERSION }} - name: Install Dependencies run: composer install --prefer-dist - name: Install latest Nextcloud API (dev-master) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index e9418648..4ab4895c 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,20 +12,19 @@ jobs: strategy: matrix: version: [min, max] - include: - - version: min - php-version: 7.1 - - version: max - php-version: 7.4 env: SERVER_BRANCH: master steps: - name: Checkout uses: actions/checkout@v2 - - name: Set up php${{ matrix.php-versions }} + - name: Determine PHP version + env: + VERSION_MINMAX: ${{ matrix.version }} + run: echo "::set-env name=PHP_VERSION::$(php tests/nextcloud-version.php --php-$VERSION_MINMAX)" + - name: Set up PHP ${{ env.PHP_VERSION }} uses: shivammathur/setup-php@v2 with: - php-version: ${{ matrix.php-version }} + php-version: ${{ env.PHP_VERSION }} - name: Install Dependencies run: composer install --prefer-dist - name: Prepare MySQL database @@ -35,8 +34,8 @@ jobs: mysql -u root -proot -e "CREATE USER 'nextcloud'@'localhost' IDENTIFIED BY '';" mysql -u root -proot -e "GRANT ALL ON nextcloud.* TO 'nextcloud'@'localhost';" - name: Select Nextcloud server branch - run: echo "::set-env name=SERVER_BRANCH::stable$(php tests/nextcloud-version.php --appinfo)" if: matrix.version == 'min' + run: echo "::set-env name=SERVER_BRANCH::stable$(php tests/nextcloud-version.php --appinfo)" - name: Prepare Nextcloud server using ${{ env.SERVER_BRANCH }} working-directory: ../ run: | |