From 4f6f658c1b1efab53b47d92432c4b08e48d17fbb Mon Sep 17 00:00:00 2001 From: luantranminh Date: Fri, 9 Aug 2024 16:32:45 +0700 Subject: [PATCH] tests: download atlas --- .github/workflows/build.yaml | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e57b6c7..eb6de9e 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -53,7 +53,7 @@ jobs: path: "./artifacts" test-tool: - name: Test Tool (${{ matrix.os }}) + name: Test tool on ${{ matrix.os }} - ${{ matrix.dialect }} needs: build strategy: matrix: @@ -84,8 +84,19 @@ jobs: shell: pwsh working-directory: ./src/Atlas.Provider.Demo run: dotnet atlas-ef -- sqlserver - - name: Check migrations for ${{ matrix.dialect }} + - name: Add current directory to PATH + shell: pwsh + if: startsWith(runner.os, 'Windows') + run: echo "::add-path::$GITHUB_WORKSPACE" + - name: Install Atlas CLI (Windows) shell: pwsh + if: startsWith(runner.os, 'Windows') + run: iwr -useb https://release.ariga.io/atlas/atlas-windows-amd64-latest.exe -OutFile atlas.exe + - name: Install Atlas CLI (Ubuntu / MacOS) + shell: pwsh + if: startsWith(runner.os, 'Linux') || startsWith(runner.os, 'macOS') + run: curl -sSf 'https://atlasgo.sh?test=1' | sh + - name: Check migrations for ${{ matrix.dialect }} working-directory: ./src/Atlas.Provider.Demo run: | atlas migrate diff --env ef --var dialect=${{ matrix.dialect }} @@ -102,7 +113,7 @@ jobs: fi test: - name: Test (${{ matrix.os }}) + name: Unit tests on ${{ matrix.os }} needs: build strategy: matrix: