From c029adf0c1f015c5407cf08ba636607d272148ec Mon Sep 17 00:00:00 2001 From: raultifrea Date: Tue, 9 Jan 2024 15:10:08 +0100 Subject: [PATCH] moved setup to another workflow --- .github/workflows/allTests.yml | 3 +-- .github/workflows/setup.yml | 29 +++++++++++++++++++++++++++++ 2 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/setup.yml diff --git a/.github/workflows/allTests.yml b/.github/workflows/allTests.yml index 838a93a..1c34637 100644 --- a/.github/workflows/allTests.yml +++ b/.github/workflows/allTests.yml @@ -49,8 +49,7 @@ jobs: steps: # Include reusable steps from above - name: 'Run reusable steps' - run: | - $(jobs.reusable-steps.steps) + uses: ./.github/workflows/setup.yml - name: Run Tests uses: cypress-io/github-action@v6 diff --git a/.github/workflows/setup.yml b/.github/workflows/setup.yml new file mode 100644 index 0000000..b7055f9 --- /dev/null +++ b/.github/workflows/setup.yml @@ -0,0 +1,29 @@ +name: Run Setup +on: workflow_call +jobs: + reusable-steps: + runs-on: ubuntu-latest + steps: + - name: Checkout Repository + uses: actions/checkout@v3 + + - name: Use Node.js 18 + uses: actions/setup-node@v3 + with: + node-version: 18.14.2 + + - name: Update & Install Ubuntu packages + run: | + env + sudo apt-get update && sudo apt-get install -y libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libgconf-2-4 libnss3 libxss1 libasound2 libxtst6 xauth xvfb + + - name: Update & Install NPM packages + run: | + npx browserslist@latest --update-db + npm ci + + - name: Clear Report + run: | + echo "Clear the report" + npm run delete-mochawesome-report + npm run delete-results \ No newline at end of file