diff --git a/.github/workflows/nightly-tests.yml b/.github/workflows/nightly-tests.yml new file mode 100644 index 00000000000..a4493195a6c --- /dev/null +++ b/.github/workflows/nightly-tests.yml @@ -0,0 +1,30 @@ +name: WP Nightly Tests +on: + schedule: + - cron: '17 4 * * *' # Run at 4:17 AM UTC. + workflow_dispatch: + +permissions: {} + +jobs: + nightly: + name: Run Tests Against Nightly + runs-on: ubuntu-20.04 + steps: + - uses: 'actions/checkout@v3' + name: 'Checkout' + with: + fetch-depth: 0 + - uses: './.github/actions/setup-woocommerce-monorepo' + name: 'Setup Monorepo' + id: 'setup-monorepo' + with: + install: '@woocommerce/plugin-woocommerce...' + build: '@woocommerce/plugin-woocommerce' + - name: 'Prepare Test Environment' + id: 'prepare-test-environment' + env: + WP_ENV_CORE: 'https://wordpress.org/nightly-builds/wordpress-latest.zip' + run: 'pnpm --filter="@woocommerce/plugin-woocommerce" env:test' + - name: 'Test' + run: 'pnpm --filter="@woocommerce/plugin-woocommerce" test:php:env'