-
Notifications
You must be signed in to change notification settings - Fork 288
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(jest-puppeteer): fix preset export
Fix #528
- Loading branch information
Showing
16 changed files
with
79 additions
and
101 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
export { PuppeteerEnvironment as default } from "./env"; | ||
export type { JestPuppeteerGlobal } from "./env"; | ||
export type { JestPuppeteerConfig } from "./config"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,5 +7,7 @@ module.exports = { | |
page: true, | ||
browser: true, | ||
context: true, | ||
puppeteerConfig: true, | ||
jestPuppeteer: true, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 0 additions & 2 deletions
2
packages/jest-environment-puppeteer/tests/browserContext-1.test.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 0 additions & 2 deletions
2
packages/jest-environment-puppeteer/tests/browserContext-2.test.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1 @@ | ||
module.exports = { | ||
globalSetup: require.resolve("jest-environment-puppeteer/setup"), | ||
globalTeardown: require.resolve("jest-environment-puppeteer/teardown"), | ||
testEnvironment: require.resolve("jest-environment-puppeteer"), | ||
setupFilesAfterEnv: [require.resolve("expect-puppeteer")], | ||
}; | ||
module.exports = require("./dist/index.js"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import type { JestPuppeteerGlobal } from "jest-environment-puppeteer"; | ||
|
||
declare global { | ||
// @ts-ignore | ||
var browser: JestPuppeteerGlobal["browser"]; | ||
// @ts-ignore | ||
var page: JestPuppeteerGlobal["page"]; | ||
// @ts-ignore | ||
var context: JestPuppeteerGlobal["context"]; | ||
// @ts-ignore | ||
var puppeteerConfig: JestPuppeteerGlobal["puppeteerConfig"]; | ||
// @ts-ignore | ||
var jestPuppeteer: JestPuppeteerGlobal["jestPuppeteer"]; | ||
} | ||
|
||
module.exports = { | ||
globalSetup: require.resolve("jest-environment-puppeteer/setup"), | ||
globalTeardown: require.resolve("jest-environment-puppeteer/teardown"), | ||
testEnvironment: require.resolve("jest-environment-puppeteer"), | ||
setupFilesAfterEnv: [require.resolve("expect-puppeteer")], | ||
}; |