fix: update modulePathIgnorePatterns for jest

This commit is contained in:
Joe Previte 2021-02-01 15:26:22 -07:00
parent 9eba2bd4fd
commit 236717ee98
No known key found for this signature in database
GPG Key ID: 2C91590C6B742C24
2 changed files with 10 additions and 1 deletions

View File

@ -147,6 +147,12 @@
"<rootDir>/release"
],
"testTimeout": 30000,
"globalSetup": "<rootDir>/test/globalSetup.ts"
"globalSetup": "<rootDir>/test/globalSetup.ts",
"modulePathIgnorePatterns": [
"<rootDir>/lib/vscode",
"<rootDir>/release-packages",
"<rootDir>/release",
"<rootDir>/release-standalone"
]
}
}

View File

@ -4,6 +4,8 @@
import { chromium, Page, Browser, BrowserContext } from "playwright"
module.exports = async () => {
console.log("🚨 Running Global Setup for Jest Tests")
console.log(" Please hang tight...")
const browser: Browser = await chromium.launch()
const context: BrowserContext = await browser.newContext()
const page: Page = await context.newPage()
@ -22,4 +24,5 @@ module.exports = async () => {
await page.close()
await browser.close()
await context.close()
console.log("✅ Global Setup for Jest Tests is now complete.")
}