name: elisp tests on: pull_request: push: branches: - master - develop env: TEST_SCRIPT: ./.github/workflows/scripts/test TESTELPA_REPO: JAremko/testelpa-develop GITHUB_WORKSPACE: ${{ github.workspace }} defaults: run: shell: bash jobs: test: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, macos-latest, windows-latest] emacs_version: [26.3, 27.1, snapshot] test_root: - core - layers/+distribution/spacemacs-base - layers/+distribution/spacemacs steps: # Installing Emacs on Unix - name: Install Emacs on UNIX continue-on-error: true id: unix-install-1 uses: purcell/setup-emacs@master with: version: ${{ matrix.emacs_version }} if: ${{ matrix.os != 'windows-latest' }} - name: Install Emacs on UNIX [retry 1] continue-on-error: true id: unix-install-2 uses: purcell/setup-emacs@master with: version: ${{ matrix.emacs_version }} if: ${{ matrix.os != 'windows-latest' && steps.unix-install-1.outcome == 'failure' }} - name: Install Emacs on UNIX [retry 2] continue-on-error: false id: unix-install-3 uses: purcell/setup-emacs@master with: version: ${{ matrix.emacs_version }} if: ${{ matrix.os != 'windows-latest' && steps.unix-install-2.outcome == 'failure' }} # Installing Emacs on Windows - name: Install Emacs on Windows continue-on-error: true id: windows-install-1 uses: jcs090218/setup-emacs-windows@master with: version: ${{ matrix.emacs_version }} if: ${{ matrix.os == 'windows-latest' }} - name: Install Emacs on Windows [retry 1] continue-on-error: true id: windows-install-2 uses: jcs090218/setup-emacs-windows@master with: version: ${{ matrix.emacs_version }} if: ${{ matrix.os == 'windows-latest' && steps.windows-install-1.outcome == 'failure' }} - name: Install Emacs on Windows [retry 2] continue-on-error: false id: windows-install-3 uses: jcs090218/setup-emacs-windows@master with: version: ${{ matrix.emacs_version }} if: ${{ matrix.os == 'windows-latest' && steps.windows-install-2.outcome == 'failure' }} # --------------------------- - uses: actions/checkout@v2 - name: Fetch Spacemacs elpa mirror run: | curl -L \ https://github.com/$TESTELPA_REPO/releases/latest/download/elpa.zip \ --output /tmp/elpa.zip - name: Unpack elpa mirror run: unzip /tmp/elpa.zip -d ../testelpa_mirror - name: Dependencies installation run: ${{ env.TEST_SCRIPT }} ${{ matrix.test_root }} installation - name: Unit testing run: ${{ env.TEST_SCRIPT }} ${{ matrix.test_root }} unit_tests - name: Functional testing run: ${{ env.TEST_SCRIPT }} ${{ matrix.test_root }} func_tests