test: re-enable testing js payloads (#27137)

This commit is contained in:
Daniel Roe 2024-05-09 21:47:31 +01:00 committed by GitHub
parent 65a2ec4592
commit 416d76ab80
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 12 additions and 1 deletions

View File

@ -199,8 +199,17 @@ jobs:
context: ["async", "default"]
manifest: ["manifest-on", "manifest-off"]
version: ["v4", "v3"]
payload: ["json", "js"]
node: [18]
exclude:
- builder: "webpack"
payload: "js"
- manifest: "manifest-off"
payload: "js"
- context: "default"
payload: "js"
- os: windows-latest
payload: "js"
- env: "dev"
builder: "webpack"
- manifest: "manifest-off"
@ -236,6 +245,7 @@ jobs:
TEST_MANIFEST: ${{ matrix.manifest }}
TEST_CONTEXT: ${{ matrix.context }}
TEST_V4: ${{ matrix.version == 'v4' }}
TEST_PAYLOAD: ${{ matrix.payload }}
SKIP_BUNDLE_SIZE: ${{ github.event_name != 'push' || matrix.env == 'dev' || matrix.builder == 'webpack' || matrix.context == 'default' || runner.os == 'Windows' }}
- uses: codecov/codecov-action@5ecb98a3c6b747ed38dc09f787459979aebb39be # v4.3.1

View File

@ -227,6 +227,7 @@ export default defineNuxtConfig({
treeshakeClientOnly: true,
asyncContext: process.env.TEST_CONTEXT === 'async',
appManifest: process.env.TEST_MANIFEST !== 'manifest-off',
renderJsonPayloads: process.env.TEST_PAYLOAD !== 'js',
headNext: true,
inlineRouteRules: true,
},

View File

@ -6,7 +6,7 @@ import { reactive, ref, shallowReactive, shallowRef } from 'vue'
import { createError } from 'h3'
import { getBrowser, url, useTestContext } from '@nuxt/test-utils/e2e'
export const isRenderingJson = true
export const isRenderingJson = process.env.TEST_PAYLOAD !== 'js'
export async function renderPage (path = '/') {
const ctx = useTestContext()