From 2b859282e0a5d8581295b1ea471a3b382f5c2178 Mon Sep 17 00:00:00 2001 From: Maxim Belkin Date: Wed, 12 Aug 2020 07:49:55 -0500 Subject: [PATCH] tests.yml: address review comments --- .github/workflows/tests.yml | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 021b9ebd30..b595877acf 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -9,12 +9,15 @@ env: jobs: tests: if: github.repository == 'Homebrew/brew' - runs-on: ${{ matrix.config.os }} + runs-on: ${{ matrix.os }} strategy: matrix: - config: - - {os: ubuntu-latest, core-tap: 'linuxbrew-core'} - - {os: macOS-latest, core-tap: 'homebrew-core'} + os: [ubuntu-latest, macOS-latest] + include: + - os: ubuntu-latest + core-tap: 'linuxbrew-core' + - os: macOS-latest + core-tap: 'homebrew-core' steps: - name: Set up Homebrew id: set-up-homebrew @@ -26,7 +29,9 @@ jobs: username: BrewTestBot - run: brew test-bot --only-cleanup-before + - run: brew config + - run: brew doctor - name: Cache Bundler RubyGems @@ -96,14 +101,14 @@ jobs: - name: Run brew readall on all taps run: brew readall --aliases - - name: Run brew style on ${{ matrix.config.core-tap }} + - name: Run brew style on ${{ matrix.core-tap }} run: brew style --display-cop-names homebrew/core - name: Run brew style on official taps run: brew style --display-cop-names homebrew/bundle homebrew/services homebrew/test-bot - name: Run brew cask style on all taps - if: matrix.config.os == 'macOS-latest' + if: matrix.os == 'macOS-latest' run: | brew tap homebrew/cask brew tap homebrew/cask-drivers @@ -121,13 +126,13 @@ jobs: vale docs/ - name: Lint Dockerfile - if: matrix.config.os == 'ubuntu-latest' + if: matrix.os == 'ubuntu-latest' run: | brew install hadolint hadolint Dockerfile - name: Build Docker image - if: matrix.config.os == 'ubuntu-latest' + if: matrix.os == 'ubuntu-latest' run: docker build -t brew --build-arg=version=16.04 . - name: Run brew test-bot --only-formulae --test-default-formula @@ -139,7 +144,7 @@ jobs: fi - name: Deploy the Docker image to GitHub and Docker Hub - if: matrix.config.os == 'ubuntu-latest' && github.ref == 'refs/heads/master' + if: matrix.os == 'ubuntu-latest' && github.ref == 'refs/heads/master' run: | docker login docker.pkg.github.com -u BrewTestBot -p ${{secrets.GITHUB_TOKEN}} docker tag brew "docker.pkg.github.com/homebrew/brew/ubuntu16.04:master"