2023-07-21 14:24:36 -05:00
|
|
|
name: Hosted tests
|
|
|
|
|
|
|
|
on:
|
|
|
|
schedule:
|
2024-02-14 08:01:53 -05:00
|
|
|
- cron: '0 0 * * 0'
|
2023-07-21 14:24:36 -05:00
|
|
|
|
|
|
|
env:
|
|
|
|
ASTRO_TELEMETRY_DISABLED: true
|
|
|
|
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
|
|
|
|
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
|
|
|
|
VERCEL_ORG_ID: ${{ secrets.VERCEL_TEST_ORG_ID }}
|
|
|
|
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_TEST_PROJECT_ID }}
|
|
|
|
VERCEL_TOKEN: ${{ secrets.VERCEL_TEST_TOKEN }}
|
|
|
|
FORCE_COLOR: true
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
test:
|
|
|
|
name: Run tests
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Check out repository
|
2024-02-09 01:35:00 -05:00
|
|
|
uses: actions/checkout@v4
|
2023-07-21 14:24:36 -05:00
|
|
|
|
|
|
|
- name: Setup PNPM
|
2024-02-28 23:49:07 -05:00
|
|
|
uses: pnpm/action-setup@v3
|
2023-07-21 14:24:36 -05:00
|
|
|
|
|
|
|
- name: Setup Node
|
2024-02-09 01:35:00 -05:00
|
|
|
uses: actions/setup-node@v4
|
2023-07-21 14:24:36 -05:00
|
|
|
with:
|
|
|
|
node-version: 18
|
2024-02-14 08:01:53 -05:00
|
|
|
cache: 'pnpm'
|
2023-07-21 14:24:36 -05:00
|
|
|
|
|
|
|
- name: Install dependencies
|
|
|
|
run: pnpm install
|
2024-02-14 08:01:53 -05:00
|
|
|
|
2023-10-10 09:06:35 -05:00
|
|
|
- name: Build Astro
|
2024-02-14 08:01:53 -05:00
|
|
|
run: pnpm turbo build --filter astro --filter @astrojs/vercel
|
2023-07-21 14:24:36 -05:00
|
|
|
|
2023-10-10 09:06:35 -05:00
|
|
|
- name: Build test project
|
2023-07-21 14:24:36 -05:00
|
|
|
working-directory: ./packages/integrations/vercel/test/hosted/hosted-astro-project
|
2024-02-14 08:01:53 -05:00
|
|
|
run: pnpm run build
|
|
|
|
|
2023-10-10 09:06:35 -05:00
|
|
|
- name: Deploy to Vercel
|
|
|
|
working-directory: ./packages/integrations/vercel/test/hosted/hosted-astro-project
|
2024-02-14 08:01:53 -05:00
|
|
|
run: pnpm dlx vercel --prod --prebuilt
|
2023-07-21 14:24:36 -05:00
|
|
|
|
2023-10-10 09:06:35 -05:00
|
|
|
- name: Test
|
2024-02-14 08:01:53 -05:00
|
|
|
run: pnpm run test:e2e:hosts
|