@bigbinary/neeto-playwright-commons 1.4.2 → 1.4.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.cjs.js CHANGED
@@ -7851,7 +7851,7 @@ const currentsConfig = {
7851
7851
  const isCI = ["staging", "review"].includes((_b = process.env.TEST_ENV) !== null && _b !== void 0 ? _b : "development") &&
7852
7852
  !!process.env.NEETO_CI_JOB_ID;
7853
7853
  const definePlaywrightConfig = (overrides) => {
7854
- const { globalOverrides = {}, useOverrides = {}, projectOverrides = [], currentsOverrides = {}, } = overrides;
7854
+ const { globalOverrides = {}, useOverrides = {}, useCustomProjects = false, projectOverrides = [], currentsOverrides = {}, } = overrides;
7855
7855
  return test.defineConfig({
7856
7856
  testDir: "./e2e/tests",
7857
7857
  fullyParallel: true,
@@ -7870,20 +7870,22 @@ const definePlaywrightConfig = (overrides) => {
7870
7870
  screenshot: "on",
7871
7871
  ...useOverrides,
7872
7872
  },
7873
- projects: [
7874
- {
7875
- name: "setup",
7876
- testMatch: "global.setup.ts",
7877
- teardown: "cleanup credentials",
7878
- },
7879
- {
7880
- name: "chromium",
7881
- use: { ...test.devices["Desktop Chrome"], storageState },
7882
- dependencies: ["setup"],
7883
- },
7884
- { name: "cleanup credentials", testMatch: "global.teardown.ts" },
7885
- ...projectOverrides,
7886
- ],
7873
+ projects: useCustomProjects
7874
+ ? projectOverrides
7875
+ : [
7876
+ {
7877
+ name: "setup",
7878
+ testMatch: "global.setup.ts",
7879
+ teardown: "cleanup credentials",
7880
+ },
7881
+ {
7882
+ name: "chromium",
7883
+ use: { ...test.devices["Desktop Chrome"], storageState },
7884
+ dependencies: ["setup"],
7885
+ },
7886
+ { name: "cleanup credentials", testMatch: "global.teardown.ts" },
7887
+ ...projectOverrides,
7888
+ ],
7887
7889
  });
7888
7890
  };
7889
7891