Skip to content

Commit

Permalink
fix (ci): reorder step
Browse files Browse the repository at this point in the history
  • Loading branch information
mickael-kerjean committed Feb 1, 2024
1 parent eeb40db commit e11aea1
Showing 1 changed file with 20 additions and 19 deletions.
39 changes: 20 additions & 19 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,24 @@ jobs:
- name: Verify
run: timeout 5 ./dist/filestash || code=$?; if [[ $code -ne 124 ]]; then exit $code; fi

test_prepare:
runs-on: ubuntu-latest
meeds: [build_frontend, build_backend]
steps:
- uses: actions/checkout@v3
- name: Clone test repo
uses: actions/checkout@v3
with:
repository: mickael-kerjean/filestash-test
ssh-key: ${{ secrets.DEPLOY_KEY_FILESTASH_TEST }}
path: test
- uses: actions/upload-artifact@v4
with:
name: test
path: test

test_frontend:
needs: [build_frontend, build_backend]
needs: test_prepare
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -89,23 +105,8 @@ jobs:
# # npx eslint .
# npx tsc

test_prepare:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Clone test repo
uses: actions/checkout@v3
with:
repository: mickael-kerjean/filestash-test
ssh-key: ${{ secrets.DEPLOY_KEY_FILESTASH_TEST }}
path: test
- uses: actions/upload-artifact@v4
with:
name: test
path: test

test_backend:
needs: [build_frontend, build_backend, test_prepare]
needs: test_prepare
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -136,7 +137,7 @@ jobs:
run: go test --tags "fts5" -count=1 $(go list ./server/... | grep -v "server/plugin" | grep -v "server/generator")

test_smoke:
needs: [build_frontend, build_backend, test_prepare]
needs: test_prepare
runs-on: ubuntu-latest
steps:
- name: Init
Expand All @@ -156,7 +157,7 @@ jobs:
cat access.log | grep -vz "ERR"
test_e2e:
needs: [test_smoke, test_prepare]
needs: test_smoke
runs-on: ubuntu-latest
container:
image: machines/puppeteer
Expand Down

0 comments on commit e11aea1

Please sign in to comment.