mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-31 23:28:34 -04:00
Use yarn pnp as module linker (#2252)
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
This commit is contained in:
parent
20a48b38d7
commit
6ba957585a
17 changed files with 271 additions and 7285 deletions
2
.github/workflows/build.yml
vendored
2
.github/workflows/build.yml
vendored
|
@ -30,7 +30,7 @@ jobs:
|
|||
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
|
||||
key: ${{ runner.os }}-${{ matrix.node }}-yarn-${{ hashFiles('**/yarn.lock') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-yarn-18
|
||||
${{ runner.os }}-yarn-${{ matrix.node }}
|
||||
- name: Set up NodeJS
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
|
|
45
.github/workflows/e2e.yml
vendored
45
.github/workflows/e2e.yml
vendored
|
@ -66,7 +66,6 @@ jobs:
|
|||
needs: build-frontend
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
# renovate: datasource=docker depName=cypress/browsers versioning=docker
|
||||
image: cypress/browsers:node16.14.2-slim-chrome103-ff102
|
||||
options: --user 1001 --shm-size=2g
|
||||
strategy:
|
||||
|
@ -78,22 +77,46 @@ jobs:
|
|||
- name: Check out repo
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Cache build
|
||||
uses: actions/cache@v3.0.5
|
||||
id: build-cache
|
||||
with:
|
||||
path: .next
|
||||
key: build-${{ github.sha }}
|
||||
|
||||
- name: Get yarn cache directory path
|
||||
id: yarn-cache-dir-path
|
||||
if: steps.build-cache.outputs.cache-hit != 'true'
|
||||
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
|
||||
|
||||
- name: Cache yarn cache
|
||||
uses: actions/cache@v3
|
||||
id: yarn-cache
|
||||
if: steps.build-cache.outputs.cache-hit != 'true'
|
||||
with:
|
||||
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
|
||||
key: ${{ runner.os }}-16-yarn-${{ hashFiles('**/yarn.lock') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-yarn-16
|
||||
|
||||
- name: Install dependencies
|
||||
if: steps.build-cache.outputs.cache-hit != 'true'
|
||||
run: yarn install --immutable
|
||||
|
||||
- name: Download built frontend
|
||||
uses: actions/download-artifact@master
|
||||
with:
|
||||
name: next-build
|
||||
path: .next
|
||||
|
||||
- uses: cypress-io/github-action@v4
|
||||
with:
|
||||
browser: ${{ matrix.browser }}
|
||||
start: 'yarn start:ci'
|
||||
parallel: true
|
||||
record: true
|
||||
group: "UI - ${{ matrix.browser }}"
|
||||
wait-on: 'http://127.0.0.1:3001/'
|
||||
wait-on-timeout: 120
|
||||
install-command: yarn install --immutable --silent
|
||||
- name: Run server
|
||||
run: yarn start:ci &
|
||||
|
||||
- name: Wait for server
|
||||
run: curl --max-time 120 http://127.0.0.1:3001/
|
||||
|
||||
- name: Run cypress
|
||||
run: "yarn cy:run:${{ matrix.browser }} --record true --parallel --group \"UI - ${{ matrix.browser }}\""
|
||||
env:
|
||||
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue