diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index afee84d131..a46eed948b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -145,44 +145,44 @@ jobs: user_service_endpoint: ${{ secrets.USER_SERVICE_ENDPOINT }} acl_provider_endpoint: ${{ secrets.ACL_PROVIDER_ENDPOINT }} - # e2e: - # needs: prepare - # runs-on: [ubuntu-latest] - # steps: - # - name: Checkout - # uses: actions/checkout@v3 - - # - name: Restore cache - # uses: ./.github/actions/restore-cache - - # - name: Set up Node - # uses: ./.github/actions/setup-node - - # - name: Build Slice Machine UI, next-adapter, init and start scripts - # run: npm run build --workspace packages/init --workspace packages/slice-machine --workspace packages/start-slicemachine --workspace packages/adapter-next - - # - name: Running End to End tests - # run: npm run test:e2e - # env: - # EMAIL: ${{ secrets.EMAIL }} - # PASSWORD: ${{ secrets.PASSWORD }} - # PRISMIC_URL: ${{ secrets.PRISMIC_URL }} - # wroom_endpoint: ${{ secrets.PRISMIC_URL }} - # authentication_server_endpoint: ${{ secrets.AUTHENTICATION_SERVER_ENDPOINT }} - # customtypesapi_endpoint: ${{ secrets.CUSTOMTYPESAPI_ENDPOINT }} - # user_service_endpoint: ${{ secrets.USER_SERVICE_ENDPOINT }} - # acl_provider_endpoint: ${{ secrets.ACL_PROVIDER_ENDPOINT }} - - # - name: Upload End to End screenshots - # uses: actions/upload-artifact@v3 - # if: failure() - # with: - # name: e2e-tests-screenshots - # path: cypress/screenshots/ + e2e: + needs: prepare + runs-on: [ubuntu-latest] + steps: + - name: Checkout + uses: actions/checkout@v3 + + - name: Restore cache + uses: ./.github/actions/restore-cache + + - name: Set up Node + uses: ./.github/actions/setup-node + + - name: Build Slice Machine UI, next-adapter, init and start scripts + run: npm run build --workspace packages/init --workspace packages/slice-machine --workspace packages/start-slicemachine --workspace packages/adapter-next + + - name: Running End to End tests + run: npm run test:e2e + env: + EMAIL: ${{ secrets.EMAIL }} + PASSWORD: ${{ secrets.PASSWORD }} + PRISMIC_URL: ${{ secrets.PRISMIC_URL }} + wroom_endpoint: ${{ secrets.PRISMIC_URL }} + authentication_server_endpoint: ${{ secrets.AUTHENTICATION_SERVER_ENDPOINT }} + customtypesapi_endpoint: ${{ secrets.CUSTOMTYPESAPI_ENDPOINT }} + user_service_endpoint: ${{ secrets.USER_SERVICE_ENDPOINT }} + acl_provider_endpoint: ${{ secrets.ACL_PROVIDER_ENDPOINT }} + + - name: Upload End to End screenshots + uses: actions/upload-artifact@v3 + if: failure() + with: + name: e2e-tests-screenshots + path: cypress/screenshots/ deployment: runs-on: ubuntu-latest - needs: [prettier, packages, packages-win32] + needs: [prettier, packages, packages-win32, e2e] if: startsWith(github.ref, 'refs/heads/dev') # Job only runs on dev branches environment: alpha steps: diff --git a/package-lock.json b/package-lock.json index 8a1c7e6e80..22eb35ed42 100644 --- a/package-lock.json +++ b/package-lock.json @@ -39561,12 +39561,12 @@ }, "packages/adapter-next": { "name": "@slicemachine/adapter-next", - "version": "0.1.3-dev-page-types.0", + "version": "0.1.3-dev-page-types.1", "license": "Apache-2.0", "dependencies": { "@prismicio/slice-simulator-core": "^0.2.7", "@prismicio/types-internal": "2.0.0-alpha.9", - "@slicemachine/plugin-kit": "0.2.1-dev-page-types.0", + "@slicemachine/plugin-kit": "0.2.1-dev-page-types.1", "common-tags": "^1.8.2", "fs-extra": "^11.1.0", "node-fetch": "^3.3.1", @@ -39698,12 +39698,12 @@ }, "packages/adapter-nuxt": { "name": "@slicemachine/adapter-nuxt", - "version": "0.1.3-dev-page-types.0", + "version": "0.1.3-dev-page-types.1", "license": "Apache-2.0", "dependencies": { "@prismicio/slice-simulator-core": "^0.2.7", "@prismicio/types-internal": "2.0.0-alpha.9", - "@slicemachine/plugin-kit": "0.2.1-dev-page-types.0", + "@slicemachine/plugin-kit": "0.2.1-dev-page-types.1", "common-tags": "^1.8.2", "fs-extra": "^11.1.0", "magicast": "^0.2.1", @@ -41625,12 +41625,12 @@ }, "packages/adapter-nuxt2": { "name": "@slicemachine/adapter-nuxt2", - "version": "0.1.3-dev-page-types.0", + "version": "0.1.3-dev-page-types.1", "license": "Apache-2.0", "dependencies": { "@prismicio/slice-simulator-core": "^0.2.7", "@prismicio/types-internal": "2.0.0-alpha.9", - "@slicemachine/plugin-kit": "0.2.1-dev-page-types.0", + "@slicemachine/plugin-kit": "0.2.1-dev-page-types.1", "common-tags": "^1.8.2", "fs-extra": "^11.1.0", "magicast": "^0.2.1", @@ -41866,12 +41866,12 @@ }, "packages/init": { "name": "@slicemachine/init", - "version": "2.0.2-dev-page-types.0", + "version": "2.0.2-dev-page-types.1", "license": "Apache-2.0", "dependencies": { "@antfu/ni": "^0.20.0", "@lihbr/listr-update-renderer": "^0.5.3", - "@slicemachine/manager": "0.2.2-dev-page-types.0", + "@slicemachine/manager": "0.2.2-dev-page-types.1", "chalk": "^4.1.2", "globby": "^13.1.3", "listr": "^0.14.3", @@ -41886,7 +41886,7 @@ }, "devDependencies": { "@size-limit/preset-small-lib": "^8.2.4", - "@slicemachine/plugin-kit": "0.2.1-dev-page-types.0", + "@slicemachine/plugin-kit": "0.2.1-dev-page-types.1", "@types/listr": "^0.14.4", "@types/prompts": "^2.4.3", "@types/semver": "^7.3.13", @@ -42046,14 +42046,14 @@ }, "packages/manager": { "name": "@slicemachine/manager", - "version": "0.2.2-dev-page-types.0", + "version": "0.2.2-dev-page-types.1", "license": "Apache-2.0", "dependencies": { "@antfu/ni": "^0.20.0", "@prismicio/custom-types-client": "^1.1.0", "@prismicio/mocks": "2.0.0-alpha.2", "@prismicio/types-internal": "2.0.0-alpha.9", - "@slicemachine/plugin-kit": "0.2.1-dev-page-types.0", + "@slicemachine/plugin-kit": "0.2.1-dev-page-types.1", "@wooorm/starry-night": "^1.6.0", "analytics-node": "^6.2.0", "cookie": "^0.5.0", @@ -42358,7 +42358,7 @@ }, "packages/plugin-kit": { "name": "@slicemachine/plugin-kit", - "version": "0.2.1-dev-page-types.0", + "version": "0.2.1-dev-page-types.1", "license": "Apache-2.0", "dependencies": { "@prismicio/types-internal": "2.0.0-alpha.9", @@ -42540,7 +42540,7 @@ }, "packages/slice-machine": { "name": "slice-machine-ui", - "version": "1.0.3-dev-page-types.0", + "version": "1.0.3-dev-page-types.1", "license": "MIT", "dependencies": { "@extractus/oembed-extractor": "^3.1.8", @@ -42548,7 +42548,7 @@ "@prismicio/editor-ui": "^0.3.0", "@prismicio/mocks": "2.0.0-alpha.2", "@prismicio/types-internal": "2.0.0-alpha.9", - "@slicemachine/manager": "0.2.2-dev-page-types.0", + "@slicemachine/manager": "0.2.2-dev-page-types.1", "fast-deep-equal": "^3.1.3", "fp-ts": "^2.13.1", "html-react-parser": "^3.0.12", @@ -42560,7 +42560,7 @@ "puppeteer": "^19.11.0", "react": "^18.2.0", "semver": "^7.3.8", - "start-slicemachine": "0.7.3-dev-page-types.0", + "start-slicemachine": "0.7.3-dev-page-types.1", "yup": "^0.32.11" }, "devDependencies": { @@ -42769,10 +42769,10 @@ } }, "packages/start-slicemachine": { - "version": "0.7.3-dev-page-types.0", + "version": "0.7.3-dev-page-types.1", "license": "Apache-2.0", "dependencies": { - "@slicemachine/manager": "0.2.2-dev-page-types.0", + "@slicemachine/manager": "0.2.2-dev-page-types.1", "body-parser": "^1.20.2", "chalk": "^4.1.2", "cors": "^2.8.5",