diff --git a/.github/workflows/docker-dev-integration-tests.yml b/.github/workflows/docker-dev-integration-tests.yml index 5593ec67..418cba56 100644 --- a/.github/workflows/docker-dev-integration-tests.yml +++ b/.github/workflows/docker-dev-integration-tests.yml @@ -12,15 +12,35 @@ jobs: CPD_DELIVERY_KEY: ${{secrets.TF_VAR_CPD_DELIVERY_KEY}} CPD_CLARITY: ${{secrets.TF_VAR_CPD_CLARITY}} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Build the Docker App Image run: cd Childrens-Social-Care-CPD; docker build . --file Dockerfile --tag childrens-social-care-cpd:latest + - name: Install Docker Compose + uses: ndeloof/install-compose-action@v0.0.1 + with: + version: latest + legacy: true # install in PATH as `docker-compose` + + - name: Verify Docker Compose installation + run: docker-compose --version + + - name: Set up Node.js + uses: actions/setup-node@v4 + with: + node-version: 'latest' + + - name: Install latest NPM version + run: npm install -g npm@latest + + - name: Verify NPM version + run: npm version + - name: Run the dev integration tests run: cd browser-tests/dev-integration-tests; docker-compose up --exit-code-from dev-integration-tests - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 name: Playwright report if: always() with: diff --git a/browser-tests/dev-integration-tests/docker-compose.yaml b/browser-tests/dev-integration-tests/docker-compose.yaml index e924002e..3e11f6a1 100644 --- a/browser-tests/dev-integration-tests/docker-compose.yaml +++ b/browser-tests/dev-integration-tests/docker-compose.yaml @@ -4,9 +4,9 @@ services: children-social-care-cpd: image: childrens-social-care-cpd:latest environment: - - CPD_AZURE_ENVIRONMENT=dev-integration + - CPD_AZURE_ENVIRONMENT=dev - CPD_CLARITY=${CPD_CLARITY} - - CPD_CONTENTFUL_ENVIRONMENT=dev-integration + - CPD_CONTENTFUL_ENVIRONMENT=dev - CPD_DELIVERY_KEY=${CPD_DELIVERY_KEY} - CPD_GOOGLEANALYTICSTAG=${CPD_GOOGLEANALYTICSTAG} - CPD_PREVIEW_KEY=${CPD_PREVIEW_KEY} @@ -22,6 +22,6 @@ services: - PLAYWRIGHT_BASE_URL=http://children-social-care-cpd - CI=1 volumes: - - ./playwright-report:/app/playwright-report/ + - ${PWD}/playwright-report:/app/playwright-report command: npx playwright test - working_dir: /app \ No newline at end of file + working_dir: /app