@zohodesk/testinglibrary 0.0.9-exp.3 → 0.0.9-n20-experimental
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/.babelrc +7 -2
- package/.eslintrc.js +5 -1
- package/.gitlab-ci.yml +191 -0
- package/README.md +151 -1
- package/build/common/data-generator/steps/DataGenerator.spec.js +19 -0
- package/build/common/data-generator/steps/DataGeneratorStepsHelper.js +19 -0
- package/build/common/multi-actor/steps/multiActorHandling.spec.js +26 -0
- package/build/common/searchFake/helpers/rpcRequestHelper.js +41 -0
- package/build/common/searchFake/steps/searchFake.spec.js +26 -0
- package/build/core/dataGenerator/DataGenerator.js +108 -0
- package/build/core/dataGenerator/DataGeneratorError.js +50 -0
- package/build/core/dataGenerator/DataGeneratorHelper.js +49 -0
- package/build/core/jest/preprocessor/jsPreprocessor.js +3 -9
- package/build/core/jest/setup/index.js +1 -7
- package/build/core/playwright/builtInFixtures/actorContext.js +75 -0
- package/build/core/playwright/builtInFixtures/addTags.js +19 -0
- package/build/core/playwright/builtInFixtures/cacheLayer.js +13 -0
- package/build/core/playwright/builtInFixtures/context.js +32 -0
- package/build/core/playwright/builtInFixtures/executionContext.js +17 -0
- package/build/core/playwright/builtInFixtures/i18N.js +41 -0
- package/build/core/playwright/builtInFixtures/index.js +46 -0
- package/build/core/playwright/builtInFixtures/page.js +38 -0
- package/build/core/playwright/builtInFixtures/unauthenticatedPage.js +18 -0
- package/build/core/playwright/clear-caches.js +49 -0
- package/build/core/playwright/codegen.js +4 -4
- package/build/core/playwright/configuration/Configuration.js +25 -0
- package/build/core/playwright/configuration/ConfigurationHelper.js +43 -0
- package/build/core/playwright/configuration/UserArgs.js +12 -0
- package/build/core/playwright/constants/browserTypes.js +12 -0
- package/build/core/playwright/constants/fileMutexConfig.js +9 -0
- package/build/core/playwright/custom-commands.js +1 -2
- package/build/core/playwright/env-initializer.js +28 -6
- package/build/core/playwright/fixtures.js +24 -0
- package/build/core/playwright/helpers/additionalProfiles.js +25 -0
- package/build/core/playwright/helpers/auth/accountLogin.js +21 -0
- package/build/core/playwright/helpers/auth/checkAuthCookies.js +41 -0
- package/build/core/playwright/helpers/auth/getUrlOrigin.js +13 -0
- package/build/core/playwright/helpers/auth/getUsers.js +118 -0
- package/build/core/playwright/helpers/auth/index.js +76 -0
- package/build/core/playwright/helpers/auth/loginDefaultStepsHelper.js +54 -0
- package/build/core/playwright/helpers/auth/loginSteps.js +51 -0
- package/build/core/playwright/helpers/checkAuthDirectory.js +27 -0
- package/build/core/playwright/helpers/configFileNameProvider.js +31 -0
- package/build/core/playwright/helpers/customFixturesHelper.js +58 -0
- package/build/core/playwright/helpers/fileMutex.js +72 -0
- package/build/core/playwright/helpers/getUserFixtures.js +23 -0
- package/build/core/playwright/helpers/mergeObjects.js +13 -0
- package/build/core/playwright/helpers/parseUserArgs.js +10 -0
- package/build/core/playwright/index.js +10 -98
- package/build/core/playwright/readConfigFile.js +66 -24
- package/build/core/playwright/report-generator.js +9 -8
- package/build/core/playwright/runner/Runner.js +22 -0
- package/build/core/playwright/runner/RunnerHelper.js +43 -0
- package/build/core/playwright/runner/RunnerTypes.js +17 -0
- package/build/core/playwright/runner/SpawnRunner.js +113 -0
- package/build/core/playwright/setup/config-creator.js +73 -24
- package/build/core/playwright/setup/config-utils.js +92 -13
- package/build/core/playwright/setup/custom-reporter.js +136 -0
- package/build/core/playwright/setup/qc-custom-reporter.js +291 -0
- package/build/core/playwright/tagProcessor.js +69 -0
- package/build/core/playwright/test-runner.js +55 -43
- package/build/core/playwright/types.js +44 -0
- package/build/core/playwright/validateFeature.js +28 -0
- package/build/decorators.d.ts +1 -1
- package/build/decorators.js +1 -1
- package/build/index.d.ts +76 -3
- package/build/index.js +63 -17
- package/build/lib/cli.js +28 -4
- package/build/lib/post-install.js +19 -11
- package/build/parser/parser.js +0 -1
- package/build/setup-folder-structure/helper.js +37 -0
- package/build/setup-folder-structure/reportEnhancement/addonScript.html +25 -0
- package/build/setup-folder-structure/reportEnhancement/reportAlteration.js +25 -0
- package/build/setup-folder-structure/samples/accountLogin-sample.js +19 -0
- package/build/setup-folder-structure/samples/actors-index.js +2 -0
- package/build/setup-folder-structure/samples/auth-setup-sample.js +10 -67
- package/build/setup-folder-structure/samples/editions-index.js +3 -0
- package/build/setup-folder-structure/samples/free-sample.json +25 -0
- package/build/setup-folder-structure/samples/git-ignore.sample.js +8 -4
- package/build/setup-folder-structure/samples/settings.json +7 -0
- package/build/setup-folder-structure/samples/testSetup-sample.js +14 -0
- package/build/setup-folder-structure/samples/uat-config-sample.js +7 -3
- package/build/setup-folder-structure/setupProject.js +33 -10
- package/build/test/core/playwright/__tests__/tagProcessor.test.js +94 -0
- package/build/test/core/playwright/__tests__/validateFeature.test.js +69 -0
- package/build/test/core/playwright/buildInFixtures/__tests__/executionContext.test.js +27 -0
- package/build/test/core/playwright/configuration/__tests__/Configuration.test.js +53 -0
- package/build/test/core/playwright/helpers/__tests__/additionalProfiles.test.js +45 -0
- package/build/test/core/playwright/helpers/__tests__/configFileNameProvider.test.js +34 -0
- package/build/test/core/playwright/helpers/__tests__/customFixturesHelper.test.js +51 -0
- package/build/test/core/playwright/helpers/__tests__/fileMutex.test.js +79 -0
- package/build/test/core/playwright/helpers/__tests__/getUsers_ListOfActors.test.js +80 -0
- package/build/test/core/playwright/runner/__tests__/RunnerHelper.test.js +16 -0
- package/build/test/core/playwright/runner/__tests__/SpawnRunner.test.js +27 -0
- package/build/utils/cliArgsToObject.js +8 -1
- package/build/utils/commonUtils.js +17 -0
- package/build/utils/fileUtils.js +60 -4
- package/build/utils/logger.js +1 -31
- package/build/utils/rootPath.js +16 -9
- package/build/utils/stepDefinitionsFormatter.js +1 -2
- package/changelog.md +167 -0
- package/jest.config.js +29 -11
- package/npm-shrinkwrap.json +10191 -6116
- package/package.json +32 -25
- package/playwright-mcp-test/node_modules/.package-lock.json +54 -0
- package/playwright-mcp-test/node_modules/@playwright/mcp/LICENSE +202 -0
- package/playwright-mcp-test/node_modules/@playwright/mcp/README.md +907 -0
- package/playwright-mcp-test/node_modules/@playwright/mcp/cli.js +24 -0
- package/playwright-mcp-test/node_modules/@playwright/mcp/config.d.ts +174 -0
- package/playwright-mcp-test/node_modules/@playwright/mcp/index.d.ts +23 -0
- package/playwright-mcp-test/node_modules/@playwright/mcp/index.js +19 -0
- package/playwright-mcp-test/node_modules/@playwright/mcp/package.json +52 -0
- package/playwright-mcp-test/node_modules/playwright/LICENSE +202 -0
- package/playwright-mcp-test/node_modules/playwright/NOTICE +5 -0
- package/playwright-mcp-test/node_modules/playwright/README.md +168 -0
- package/playwright-mcp-test/node_modules/playwright/ThirdPartyNotices.txt +6277 -0
- package/playwright-mcp-test/node_modules/playwright/cli.js +19 -0
- package/playwright-mcp-test/node_modules/playwright/index.d.ts +17 -0
- package/playwright-mcp-test/node_modules/playwright/index.js +17 -0
- package/playwright-mcp-test/node_modules/playwright/index.mjs +18 -0
- package/playwright-mcp-test/node_modules/playwright/jsx-runtime.js +42 -0
- package/playwright-mcp-test/node_modules/playwright/jsx-runtime.mjs +21 -0
- package/playwright-mcp-test/node_modules/playwright/lib/agents/generateAgents.js +368 -0
- package/playwright-mcp-test/node_modules/playwright/lib/agents/generator.agent.md +101 -0
- package/playwright-mcp-test/node_modules/playwright/lib/agents/healer.agent.md +77 -0
- package/playwright-mcp-test/node_modules/playwright/lib/agents/planner.agent.md +138 -0
- package/playwright-mcp-test/node_modules/playwright/lib/agents/test-coverage.prompt.md +31 -0
- package/playwright-mcp-test/node_modules/playwright/lib/agents/test-generate.prompt.md +8 -0
- package/playwright-mcp-test/node_modules/playwright/lib/agents/test-heal.prompt.md +6 -0
- package/playwright-mcp-test/node_modules/playwright/lib/agents/test-plan.prompt.md +9 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/config.js +280 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/configLoader.js +344 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/esmLoaderHost.js +102 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/expectBundle.js +52 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/expectBundleImpl.js +389 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/fixtures.js +302 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/globals.js +58 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/ipc.js +60 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/poolBuilder.js +85 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/process.js +104 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/suiteUtils.js +140 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/test.js +321 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/testLoader.js +101 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/testType.js +298 -0
- package/playwright-mcp-test/node_modules/playwright/lib/common/validators.js +68 -0
- package/playwright-mcp-test/node_modules/playwright/lib/fsWatcher.js +67 -0
- package/playwright-mcp-test/node_modules/playwright/lib/index.js +682 -0
- package/playwright-mcp-test/node_modules/playwright/lib/internalsForTest.js +42 -0
- package/playwright-mcp-test/node_modules/playwright/lib/isomorphic/events.js +77 -0
- package/playwright-mcp-test/node_modules/playwright/lib/isomorphic/folders.js +30 -0
- package/playwright-mcp-test/node_modules/playwright/lib/isomorphic/stringInternPool.js +69 -0
- package/playwright-mcp-test/node_modules/playwright/lib/isomorphic/teleReceiver.js +508 -0
- package/playwright-mcp-test/node_modules/playwright/lib/isomorphic/teleSuiteUpdater.js +137 -0
- package/playwright-mcp-test/node_modules/playwright/lib/isomorphic/testServerConnection.js +211 -0
- package/playwright-mcp-test/node_modules/playwright/lib/isomorphic/testServerInterface.js +16 -0
- package/playwright-mcp-test/node_modules/playwright/lib/isomorphic/testTree.js +334 -0
- package/playwright-mcp-test/node_modules/playwright/lib/isomorphic/types.d.js +16 -0
- package/playwright-mcp-test/node_modules/playwright/lib/loader/loaderMain.js +59 -0
- package/playwright-mcp-test/node_modules/playwright/lib/matchers/expect.js +325 -0
- package/playwright-mcp-test/node_modules/playwright/lib/matchers/matcherHint.js +87 -0
- package/playwright-mcp-test/node_modules/playwright/lib/matchers/matchers.js +366 -0
- package/playwright-mcp-test/node_modules/playwright/lib/matchers/toBeTruthy.js +73 -0
- package/playwright-mcp-test/node_modules/playwright/lib/matchers/toEqual.js +99 -0
- package/playwright-mcp-test/node_modules/playwright/lib/matchers/toHaveURL.js +102 -0
- package/playwright-mcp-test/node_modules/playwright/lib/matchers/toMatchAriaSnapshot.js +159 -0
- package/playwright-mcp-test/node_modules/playwright/lib/matchers/toMatchSnapshot.js +341 -0
- package/playwright-mcp-test/node_modules/playwright/lib/matchers/toMatchText.js +99 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/actions.d.js +16 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/browserContextFactory.js +296 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/browserServerBackend.js +76 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/codegen.js +66 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/config.js +385 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/context.js +287 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/response.js +228 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/sessionLog.js +160 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tab.js +280 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/common.js +63 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/console.js +44 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/dialogs.js +60 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/evaluate.js +69 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/files.js +58 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/form.js +73 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/install.js +69 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/keyboard.js +84 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/mouse.js +107 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/navigate.js +62 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/network.js +54 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/pdf.js +59 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/screenshot.js +106 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/snapshot.js +181 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/tabs.js +67 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/tool.js +49 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/tracing.js +74 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/utils.js +89 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/verify.js +153 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools/wait.js +63 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/tools.js +80 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/browser/watchdog.js +44 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/config.d.js +16 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/extension/cdpRelay.js +351 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/extension/extensionContextFactory.js +75 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/extension/protocol.js +28 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/index.js +61 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/log.js +35 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/program.js +96 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/sdk/bundle.js +81 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/sdk/exports.js +32 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/sdk/http.js +187 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/sdk/inProcessTransport.js +71 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/sdk/mdb.js +206 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/sdk/proxyBackend.js +128 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/sdk/server.js +189 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/sdk/tool.js +51 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/test/browserBackend.js +98 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/test/generatorTools.js +122 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/test/plannerTools.js +46 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/test/seed.js +82 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/test/streams.js +39 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/test/testBackend.js +97 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/test/testContext.js +176 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/test/testTool.js +30 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcp/test/testTools.js +115 -0
- package/playwright-mcp-test/node_modules/playwright/lib/mcpBundleImpl.js +41 -0
- package/playwright-mcp-test/node_modules/playwright/lib/plugins/gitCommitInfoPlugin.js +198 -0
- package/playwright-mcp-test/node_modules/playwright/lib/plugins/index.js +28 -0
- package/playwright-mcp-test/node_modules/playwright/lib/plugins/webServerPlugin.js +209 -0
- package/playwright-mcp-test/node_modules/playwright/lib/program.js +411 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/base.js +609 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/blob.js +135 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/dot.js +82 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/empty.js +32 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/github.js +128 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/html.js +623 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/internalReporter.js +130 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/json.js +254 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/junit.js +232 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/line.js +113 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/list.js +235 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/listModeReporter.js +69 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/markdown.js +144 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/merge.js +541 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/multiplexer.js +104 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/reporterV2.js +102 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/teleEmitter.js +298 -0
- package/playwright-mcp-test/node_modules/playwright/lib/reporters/versions/blobV1.js +16 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/dispatcher.js +491 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/failureTracker.js +72 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/lastRun.js +77 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/loadUtils.js +334 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/loaderHost.js +89 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/processHost.js +161 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/projectUtils.js +241 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/rebase.js +189 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/reporters.js +139 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/sigIntWatcher.js +96 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/taskRunner.js +127 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/tasks.js +410 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/testGroups.js +117 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/testRunner.js +390 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/testServer.js +264 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/uiModeReporter.js +30 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/vcs.js +72 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/watchMode.js +395 -0
- package/playwright-mcp-test/node_modules/playwright/lib/runner/workerHost.js +95 -0
- package/playwright-mcp-test/node_modules/playwright/lib/third_party/pirates.js +62 -0
- package/playwright-mcp-test/node_modules/playwright/lib/third_party/tsconfig-loader.js +103 -0
- package/playwright-mcp-test/node_modules/playwright/lib/transform/babelBundle.js +43 -0
- package/playwright-mcp-test/node_modules/playwright/lib/transform/babelBundleImpl.js +461 -0
- package/playwright-mcp-test/node_modules/playwright/lib/transform/compilationCache.js +272 -0
- package/playwright-mcp-test/node_modules/playwright/lib/transform/esmLoader.js +104 -0
- package/playwright-mcp-test/node_modules/playwright/lib/transform/portTransport.js +67 -0
- package/playwright-mcp-test/node_modules/playwright/lib/transform/transform.js +293 -0
- package/playwright-mcp-test/node_modules/playwright/lib/util.js +403 -0
- package/playwright-mcp-test/node_modules/playwright/lib/utilsBundle.js +43 -0
- package/playwright-mcp-test/node_modules/playwright/lib/utilsBundleImpl.js +100 -0
- package/playwright-mcp-test/node_modules/playwright/lib/worker/fixtureRunner.js +258 -0
- package/playwright-mcp-test/node_modules/playwright/lib/worker/testInfo.js +514 -0
- package/playwright-mcp-test/node_modules/playwright/lib/worker/testTracing.js +344 -0
- package/playwright-mcp-test/node_modules/playwright/lib/worker/timeoutManager.js +174 -0
- package/playwright-mcp-test/node_modules/playwright/lib/worker/util.js +31 -0
- package/playwright-mcp-test/node_modules/playwright/lib/worker/workerMain.js +520 -0
- package/playwright-mcp-test/node_modules/playwright/package.json +72 -0
- package/playwright-mcp-test/node_modules/playwright/test.d.ts +18 -0
- package/playwright-mcp-test/node_modules/playwright/test.js +24 -0
- package/playwright-mcp-test/node_modules/playwright/test.mjs +33 -0
- package/playwright-mcp-test/node_modules/playwright/types/test.d.ts +10185 -0
- package/playwright-mcp-test/node_modules/playwright/types/testReporter.d.ts +821 -0
- package/playwright-mcp-test/node_modules/playwright-core/LICENSE +202 -0
- package/playwright-mcp-test/node_modules/playwright-core/NOTICE +5 -0
- package/playwright-mcp-test/node_modules/playwright-core/README.md +3 -0
- package/playwright-mcp-test/node_modules/playwright-core/ThirdPartyNotices.txt +1161 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/install_media_pack.ps1 +5 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/install_webkit_wsl.ps1 +35 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_chrome_beta_linux.sh +42 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_chrome_beta_mac.sh +13 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_chrome_beta_win.ps1 +24 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_chrome_stable_linux.sh +42 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_chrome_stable_mac.sh +12 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_chrome_stable_win.ps1 +24 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_msedge_beta_linux.sh +48 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_msedge_beta_mac.sh +11 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_msedge_beta_win.ps1 +23 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_msedge_dev_linux.sh +48 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_msedge_dev_mac.sh +11 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_msedge_dev_win.ps1 +23 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_msedge_stable_linux.sh +48 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_msedge_stable_mac.sh +11 -0
- package/playwright-mcp-test/node_modules/playwright-core/bin/reinstall_msedge_stable_win.ps1 +24 -0
- package/playwright-mcp-test/node_modules/playwright-core/browsers.json +80 -0
- package/playwright-mcp-test/node_modules/playwright-core/cli.js +18 -0
- package/playwright-mcp-test/node_modules/playwright-core/index.d.ts +17 -0
- package/playwright-mcp-test/node_modules/playwright-core/index.js +32 -0
- package/playwright-mcp-test/node_modules/playwright-core/index.mjs +28 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/androidServerImpl.js +65 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/browserServerImpl.js +120 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/cli/driver.js +97 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/cli/program.js +634 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/cli/programWithTestStub.js +74 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/accessibility.js +49 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/android.js +361 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/api.js +137 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/artifact.js +79 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/browser.js +163 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/browserContext.js +529 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/browserType.js +184 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/cdpSession.js +51 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/channelOwner.js +194 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/clientHelper.js +64 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/clientInstrumentation.js +55 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/clientStackTrace.js +69 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/clock.js +68 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/connection.js +314 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/consoleMessage.js +54 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/coverage.js +44 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/dialog.js +56 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/download.js +62 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/electron.js +138 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/elementHandle.js +281 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/errors.js +77 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/eventEmitter.js +314 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/events.js +99 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/fetch.js +369 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/fileChooser.js +46 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/fileUtils.js +34 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/frame.js +408 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/harRouter.js +87 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/input.js +84 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/jsHandle.js +109 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/jsonPipe.js +39 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/localUtils.js +60 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/locator.js +369 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/network.js +747 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/page.js +721 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/platform.js +74 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/playwright.js +71 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/selectors.js +55 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/stream.js +39 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/timeoutSettings.js +79 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/tracing.js +117 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/types.js +28 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/video.js +59 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/waiter.js +142 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/webError.js +39 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/webSocket.js +93 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/worker.js +63 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/client/writableStream.js +39 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/generated/bindingsControllerSource.js +28 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/generated/clockSource.js +28 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/generated/injectedScriptSource.js +28 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/generated/pollingRecorderSource.js +28 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/generated/storageScriptSource.js +28 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/generated/utilityScriptSource.js +28 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/generated/webSocketMockSource.js +336 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/inProcessFactory.js +60 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/inprocess.js +3 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/outofprocess.js +76 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/protocol/serializers.js +192 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/protocol/validator.js +2912 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/protocol/validatorPrimitives.js +193 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/remote/playwrightConnection.js +129 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/remote/playwrightServer.js +335 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/accessibility.js +69 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/android/android.js +465 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/android/backendAdb.js +177 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/artifact.js +127 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/bidiBrowser.js +490 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/bidiChromium.js +153 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/bidiConnection.js +212 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/bidiExecutionContext.js +221 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/bidiFirefox.js +130 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/bidiInput.js +146 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/bidiNetworkManager.js +383 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/bidiOverCdp.js +102 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/bidiPage.js +554 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/bidiPdf.js +106 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/third_party/bidiCommands.d.js +22 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/third_party/bidiDeserializer.js +98 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/third_party/bidiKeyboard.js +256 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/third_party/bidiProtocol.js +24 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/third_party/bidiProtocolCore.js +179 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/third_party/bidiProtocolPermissions.js +42 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/third_party/bidiSerializer.js +148 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/bidi/third_party/firefoxPrefs.js +259 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/browser.js +149 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/browserContext.js +695 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/browserType.js +328 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/callLog.js +82 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/appIcon.png +0 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/chromium.js +402 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/chromiumSwitches.js +95 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crAccessibility.js +263 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crBrowser.js +502 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crConnection.js +202 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crCoverage.js +235 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crDevTools.js +113 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crDragDrop.js +131 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crExecutionContext.js +146 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crInput.js +187 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crNetworkManager.js +666 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crPage.js +1069 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crPdf.js +121 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crProtocolHelper.js +145 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/crServiceWorker.js +123 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/defaultFontFamilies.js +162 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/protocol.d.js +16 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/chromium/videoRecorder.js +113 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/clock.js +149 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/codegen/csharp.js +327 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/codegen/java.js +274 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/codegen/javascript.js +270 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/codegen/jsonl.js +52 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/codegen/language.js +132 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/codegen/languages.js +68 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/codegen/python.js +279 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/codegen/types.js +16 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/console.js +53 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/cookieStore.js +206 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/debugController.js +191 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/debugger.js +119 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/deviceDescriptors.js +39 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/deviceDescriptorsSource.json +1779 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dialog.js +116 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/androidDispatcher.js +325 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/artifactDispatcher.js +118 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/browserContextDispatcher.js +364 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/browserDispatcher.js +118 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/browserTypeDispatcher.js +64 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/cdpSessionDispatcher.js +44 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/debugControllerDispatcher.js +78 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/dialogDispatcher.js +47 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/dispatcher.js +371 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/electronDispatcher.js +89 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/elementHandlerDispatcher.js +181 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/frameDispatcher.js +227 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/jsHandleDispatcher.js +85 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/jsonPipeDispatcher.js +58 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/localUtilsDispatcher.js +149 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/networkDispatchers.js +213 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/pageDispatcher.js +401 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/playwrightDispatcher.js +108 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/streamDispatcher.js +67 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/tracingDispatcher.js +68 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/webSocketRouteDispatcher.js +165 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dispatchers/writableStreamDispatcher.js +79 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/dom.js +806 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/download.js +70 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/electron/electron.js +270 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/electron/loader.js +29 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/errors.js +69 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/fetch.js +621 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/fileChooser.js +43 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/fileUploadUtils.js +84 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/firefox/ffAccessibility.js +238 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/firefox/ffBrowser.js +428 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/firefox/ffConnection.js +147 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/firefox/ffExecutionContext.js +150 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/firefox/ffInput.js +159 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/firefox/ffNetworkManager.js +256 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/firefox/ffPage.js +503 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/firefox/firefox.js +116 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/firefox/protocol.d.js +16 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/formData.js +147 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/frameSelectors.js +154 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/frames.js +1455 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/har/harRecorder.js +147 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/har/harTracer.js +607 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/harBackend.js +157 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/helper.js +96 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/index.js +58 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/input.js +273 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/instrumentation.js +69 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/javascript.js +291 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/launchApp.js +128 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/localUtils.js +214 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/macEditingCommands.js +143 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/network.js +629 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/page.js +867 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/pipeTransport.js +89 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/playwright.js +69 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/progress.js +112 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/protocolError.js +52 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/recorder/chat.js +161 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/recorder/recorderApp.js +387 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/recorder/recorderRunner.js +138 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/recorder/recorderSignalProcessor.js +83 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/recorder/recorderUtils.js +157 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/recorder/throttledFile.js +57 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/recorder.js +499 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/registry/browserFetcher.js +175 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/registry/dependencies.js +371 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/registry/index.js +1361 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/registry/nativeDeps.js +1280 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/registry/oopDownloadBrowserMain.js +124 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/screenshotter.js +333 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/selectors.js +112 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/socksClientCertificatesInterceptor.js +383 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/socksInterceptor.js +95 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/trace/recorder/snapshotter.js +147 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/trace/recorder/snapshotterInjected.js +541 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/trace/recorder/tracing.js +602 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/trace/test/inMemorySnapshotter.js +87 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/trace/viewer/traceViewer.js +230 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/transport.js +181 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/types.js +28 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/usKeyboardLayout.js +145 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/ascii.js +44 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/comparators.js +139 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/crypto.js +216 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/debug.js +42 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/debugLogger.js +122 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/env.js +73 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/eventsHelper.js +39 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/expectUtils.js +38 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/fileUtils.js +191 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/happyEyeballs.js +207 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/hostPlatform.js +123 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/httpServer.js +218 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/imageUtils.js +146 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/image_tools/colorUtils.js +89 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/image_tools/compare.js +109 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/image_tools/imageChannel.js +78 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/image_tools/stats.js +102 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/linuxUtils.js +71 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/network.js +233 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/nodePlatform.js +148 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/pipeTransport.js +84 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/processLauncher.js +241 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/profiler.js +65 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/socksProxy.js +511 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/spawnAsync.js +41 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/task.js +51 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/userAgent.js +98 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/wsServer.js +121 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/zipFile.js +74 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/utils/zones.js +57 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/protocol.d.js +16 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/webkit.js +119 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/wkAccessibility.js +237 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/wkBrowser.js +339 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/wkConnection.js +149 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/wkExecutionContext.js +154 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/wkInput.js +181 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/wkInterceptableRequest.js +169 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/wkPage.js +1134 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/wkProvisionalPage.js +83 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/wkWorkers.js +104 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/wsl/webkit-wsl-transport-client.js +74 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/server/webkit/wsl/webkit-wsl-transport-server.js +113 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/third_party/pixelmatch.js +255 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/ariaSnapshot.js +392 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/assert.js +31 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/colors.js +72 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/cssParser.js +245 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/cssTokenizer.js +1051 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/headers.js +53 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/locatorGenerators.js +689 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/locatorParser.js +176 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/locatorUtils.js +81 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/manualPromise.js +114 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/mimeType.js +459 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/multimap.js +80 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/protocolFormatter.js +81 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/protocolMetainfo.js +321 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/rtti.js +43 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/selectorParser.js +386 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/semaphore.js +54 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/stackTrace.js +158 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/stringUtils.js +155 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/time.js +49 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/timeoutRunner.js +66 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/traceUtils.js +58 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/types.js +16 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/urlMatch.js +179 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils/isomorphic/utilityScriptSerializers.js +251 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utils.js +109 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utilsBundle.js +112 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utilsBundleImpl/index.js +218 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/utilsBundleImpl/xdg-open +1066 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/htmlReport/index.html +84 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/recorder/assets/codeMirrorModule-C3UTv-Ge.css +1 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/recorder/assets/codeMirrorModule-DX585GyR.js +25 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/recorder/assets/codicon-DCmgc-ay.ttf +0 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/recorder/assets/index-DjadjNw5.js +193 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/recorder/assets/index-Ri0uHF7I.css +1 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/recorder/index.html +29 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/recorder/playwright-logo.svg +9 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/assets/codeMirrorModule-Cw-6jrKz.js +25 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/assets/defaultSettingsView-BZIhX7gh.js +266 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/assets/xtermModule-CsJ4vdCR.js +9 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/codeMirrorModule.C3UTv-Ge.css +1 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/codicon.DCmgc-ay.ttf +0 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/defaultSettingsView.BEjzWGz-.css +1 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/index.Dk_obRs3.js +2 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/index.I8N9v4jT.css +1 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/index.html +43 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/manifest.webmanifest +16 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/playwright-logo.svg +9 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/snapshot.html +21 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/sw.bundle.js +3 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/uiMode.Bai-qGIw.js +5 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/uiMode.Btcz36p_.css +1 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/uiMode.html +17 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/vite/traceViewer/xtermModule.DYP7pi_n.css +32 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/zipBundle.js +34 -0
- package/playwright-mcp-test/node_modules/playwright-core/lib/zipBundleImpl.js +5 -0
- package/playwright-mcp-test/node_modules/playwright-core/package.json +42 -0
- package/playwright-mcp-test/node_modules/playwright-core/types/protocol.d.ts +23130 -0
- package/playwright-mcp-test/node_modules/playwright-core/types/structs.d.ts +45 -0
- package/playwright-mcp-test/node_modules/playwright-core/types/types.d.ts +22872 -0
- package/playwright-mcp-test/package-lock.json +76 -0
- package/playwright.config.js +0 -50
- package/uat/test-results/.last-run.json +4 -0
- package/zohodesk-testinglibrary-3.2.13.tgz +0 -0
- package/Changelog.md +0 -54
- package/build/bdd-framework/cli/commands/env.js +0 -43
- package/build/bdd-framework/cli/commands/export.js +0 -48
- package/build/bdd-framework/cli/commands/test.js +0 -59
- package/build/bdd-framework/cli/index.js +0 -11
- package/build/bdd-framework/cli/options.js +0 -20
- package/build/bdd-framework/cli/worker.js +0 -13
- package/build/bdd-framework/config/dir.js +0 -27
- package/build/bdd-framework/config/env.js +0 -49
- package/build/bdd-framework/config/index.js +0 -91
- package/build/bdd-framework/cucumber/buildStepDefinition.js +0 -43
- package/build/bdd-framework/cucumber/gherkin.d.js +0 -5
- package/build/bdd-framework/cucumber/gherkin.d.ts +0 -45
- package/build/bdd-framework/cucumber/loadConfig.js +0 -17
- package/build/bdd-framework/cucumber/loadFeatures.js +0 -39
- package/build/bdd-framework/cucumber/loadSnippetBuilder.js +0 -20
- package/build/bdd-framework/cucumber/loadSources.js +0 -57
- package/build/bdd-framework/cucumber/loadSteps.js +0 -35
- package/build/bdd-framework/decorators.js +0 -22
- package/build/bdd-framework/gen/formatter.js +0 -88
- package/build/bdd-framework/gen/i18n.js +0 -35
- package/build/bdd-framework/gen/index.js +0 -160
- package/build/bdd-framework/gen/poms.js +0 -46
- package/build/bdd-framework/gen/testFile.js +0 -356
- package/build/bdd-framework/gen/testNode.js +0 -48
- package/build/bdd-framework/gen/testPoms.js +0 -123
- package/build/bdd-framework/index.js +0 -45
- package/build/bdd-framework/playwright/fixtureParameterNames.js +0 -77
- package/build/bdd-framework/playwright/getLocationInFile.js +0 -46
- package/build/bdd-framework/playwright/loadConfig.js +0 -42
- package/build/bdd-framework/playwright/testTypeImpl.js +0 -41
- package/build/bdd-framework/playwright/transform.js +0 -80
- package/build/bdd-framework/playwright/types.js +0 -5
- package/build/bdd-framework/playwright/utils.js +0 -34
- package/build/bdd-framework/run/bddFixtures.js +0 -108
- package/build/bdd-framework/run/bddWorld.js +0 -87
- package/build/bdd-framework/snippets/index.js +0 -131
- package/build/bdd-framework/snippets/snippetSyntax.js +0 -41
- package/build/bdd-framework/snippets/snippetSyntaxDecorators.js +0 -26
- package/build/bdd-framework/snippets/snippetSyntaxTs.js +0 -18
- package/build/bdd-framework/stepDefinitions/createBdd.js +0 -49
- package/build/bdd-framework/stepDefinitions/createDecorators.js +0 -109
- package/build/bdd-framework/stepDefinitions/decorators/poms.js +0 -50
- package/build/bdd-framework/stepDefinitions/decorators/steps.js +0 -94
- package/build/bdd-framework/stepDefinitions/defineStep.js +0 -61
- package/build/bdd-framework/stepDefinitions/stepConfig.js +0 -24
- package/build/bdd-framework/utils/index.js +0 -50
- package/build/bdd-framework/utils/jsStringWrap.js +0 -44
- package/build/bdd-framework/utils/logger.js +0 -29
- package/build/setup-folder-structure/samples/authUsers-sample.json +0 -9
- package/build/setup-folder-structure/samples/env-config-sample.json +0 -21
package/.babelrc
CHANGED
|
@@ -6,14 +6,19 @@
|
|
|
6
6
|
"targets": {
|
|
7
7
|
"node": "14"
|
|
8
8
|
},
|
|
9
|
+
// We are adding plugin @babel/plugin-transform-destructuring to ensure babel does not transform the destructing
|
|
10
|
+
// as playwright does not allow parameters without destrucring
|
|
9
11
|
"exclude": ["@babel/plugin-transform-destructuring"]
|
|
10
12
|
}
|
|
11
13
|
]
|
|
12
14
|
],
|
|
13
15
|
"plugins": [
|
|
14
|
-
["@babel/plugin-transform-runtime"]
|
|
16
|
+
["@babel/plugin-transform-runtime"],
|
|
17
|
+
["@babel/plugin-transform-modules-commonjs"]
|
|
15
18
|
],
|
|
19
|
+
// Ignored as these are setup files needed during init script. Files inside that folder are copied not transformed
|
|
16
20
|
"ignore": [
|
|
17
|
-
"./src/setup-folder-structure/samples"
|
|
21
|
+
"./src/setup-folder-structure/samples",
|
|
22
|
+
"./src/common/**"
|
|
18
23
|
]
|
|
19
24
|
}
|
package/.eslintrc.js
CHANGED
|
@@ -22,6 +22,10 @@ module.exports = {
|
|
|
22
22
|
"sourceType": "module"
|
|
23
23
|
},
|
|
24
24
|
"rules": {
|
|
25
|
-
"indent": ["error", 2]
|
|
25
|
+
"indent": ["error", 2, { "SwitchCase": 1 }],
|
|
26
|
+
"no-empty-pattern": "off",
|
|
27
|
+
"comma-dangle": ["error", "never"],
|
|
28
|
+
"curly": ["error"],
|
|
29
|
+
"brace-style": "error"
|
|
26
30
|
}
|
|
27
31
|
}
|
package/.gitlab-ci.yml
ADDED
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
image: repository.desk.csez.zohocorpin.com/base-image/testing-framework-gitlab-runne-base:v3
|
|
2
|
+
|
|
3
|
+
workflow:
|
|
4
|
+
rules:
|
|
5
|
+
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
|
|
6
|
+
when: always
|
|
7
|
+
- if: $CI_PIPELINE_SOURCE == "web"
|
|
8
|
+
when: always
|
|
9
|
+
|
|
10
|
+
stages:
|
|
11
|
+
- build
|
|
12
|
+
- unit
|
|
13
|
+
- uat
|
|
14
|
+
|
|
15
|
+
default:
|
|
16
|
+
cache:
|
|
17
|
+
key: build-cache
|
|
18
|
+
paths:
|
|
19
|
+
- node_modules
|
|
20
|
+
- build
|
|
21
|
+
- npm-shrinkwrap.json
|
|
22
|
+
|
|
23
|
+
# Install dependencies stage
|
|
24
|
+
build:
|
|
25
|
+
stage: build
|
|
26
|
+
script:
|
|
27
|
+
- npm -v
|
|
28
|
+
- node -v
|
|
29
|
+
- npm install --ignore-scripts
|
|
30
|
+
- npm run build
|
|
31
|
+
- npm install
|
|
32
|
+
- npm shrinkwrap
|
|
33
|
+
- npm run build
|
|
34
|
+
|
|
35
|
+
# Unit tests stage
|
|
36
|
+
unit:
|
|
37
|
+
stage: unit
|
|
38
|
+
script:
|
|
39
|
+
- npm run test
|
|
40
|
+
artifacts:
|
|
41
|
+
when: always
|
|
42
|
+
paths:
|
|
43
|
+
- unit_reports
|
|
44
|
+
|
|
45
|
+
# UAT tests stage
|
|
46
|
+
uat-auth:
|
|
47
|
+
stage: uat
|
|
48
|
+
script:
|
|
49
|
+
- cd examples
|
|
50
|
+
- npm install $(npm pack ../../testing-framework | tail -1)
|
|
51
|
+
- output=$(npm run uatauth)
|
|
52
|
+
- echo "$output"
|
|
53
|
+
- node ../ValidateUATReport.js examples
|
|
54
|
+
|
|
55
|
+
artifacts:
|
|
56
|
+
when: always
|
|
57
|
+
paths:
|
|
58
|
+
- examples/uat/playwright-report
|
|
59
|
+
|
|
60
|
+
uat-noauth:
|
|
61
|
+
stage: uat
|
|
62
|
+
script:
|
|
63
|
+
- cd examples
|
|
64
|
+
- npm install $(npm pack ../../testing-framework | tail -1)
|
|
65
|
+
- output=$(npm run uatnoauth)
|
|
66
|
+
- echo "$output"
|
|
67
|
+
- node ../ValidateUATReport.js examples
|
|
68
|
+
|
|
69
|
+
artifacts:
|
|
70
|
+
when: always
|
|
71
|
+
paths:
|
|
72
|
+
- examples/uat/playwright-report
|
|
73
|
+
|
|
74
|
+
uat-profile:
|
|
75
|
+
stage: uat
|
|
76
|
+
script:
|
|
77
|
+
- cd examples
|
|
78
|
+
- npm install $(npm pack ../../testing-framework | tail -1)
|
|
79
|
+
- output=$(npm run uatprofile)
|
|
80
|
+
- echo "$output"
|
|
81
|
+
- node ../ValidateUATReport.js examples
|
|
82
|
+
|
|
83
|
+
artifacts:
|
|
84
|
+
when: always
|
|
85
|
+
paths:
|
|
86
|
+
- examples/uat/playwright-report
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
uat-unauth:
|
|
90
|
+
stage: uat
|
|
91
|
+
script:
|
|
92
|
+
- cd examples
|
|
93
|
+
- npm install $(npm pack ../../testing-framework | tail -1)
|
|
94
|
+
- output=$(npm run uatunauth)
|
|
95
|
+
- echo "$output"
|
|
96
|
+
- node ../ValidateUATReport.js examples
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
artifacts:
|
|
100
|
+
when: always
|
|
101
|
+
paths:
|
|
102
|
+
- examples/uat/playwright-report
|
|
103
|
+
|
|
104
|
+
uat-nobdd:
|
|
105
|
+
stage: uat
|
|
106
|
+
script:
|
|
107
|
+
- cd nobdd
|
|
108
|
+
- npm install $(npm pack ../../testing-framework | tail -1)
|
|
109
|
+
- output=$(npm run uatnobdd -- --headless)
|
|
110
|
+
- echo "$output"
|
|
111
|
+
- node ../ValidateUATReport.js nobdd
|
|
112
|
+
|
|
113
|
+
|
|
114
|
+
artifacts:
|
|
115
|
+
when: always
|
|
116
|
+
paths:
|
|
117
|
+
- nobdd/uat/playwright-report
|
|
118
|
+
|
|
119
|
+
|
|
120
|
+
uatmodule:
|
|
121
|
+
stage: uat
|
|
122
|
+
script:
|
|
123
|
+
- cd examples
|
|
124
|
+
- npm install $(npm pack ../../testing-framework | tail -1)
|
|
125
|
+
- output=$(npm run uatmodule)
|
|
126
|
+
- echo "$output"
|
|
127
|
+
- node ../ValidateUATReport.js examples
|
|
128
|
+
|
|
129
|
+
|
|
130
|
+
artifacts:
|
|
131
|
+
when: always
|
|
132
|
+
paths:
|
|
133
|
+
- examples/uat/playwright-report
|
|
134
|
+
|
|
135
|
+
uatconfigmodule:
|
|
136
|
+
stage: uat
|
|
137
|
+
script:
|
|
138
|
+
- cd examples
|
|
139
|
+
- npm install $(npm pack ../../testing-framework | tail -1)
|
|
140
|
+
- output=$(npm run uatconfigmodule)
|
|
141
|
+
- echo "$output"
|
|
142
|
+
- node ../ValidateUATReport.js examples
|
|
143
|
+
|
|
144
|
+
artifacts:
|
|
145
|
+
when: always
|
|
146
|
+
paths:
|
|
147
|
+
- examples/uat/playwright-report
|
|
148
|
+
|
|
149
|
+
uat-smoketest:
|
|
150
|
+
stage: uat
|
|
151
|
+
script:
|
|
152
|
+
- cd examples
|
|
153
|
+
- npm install $(npm pack ../../testing-framework | tail -1)
|
|
154
|
+
- output=$(npm run uat-smoketest)
|
|
155
|
+
- echo "$output"
|
|
156
|
+
- node ../ValidateUATReport.js examples
|
|
157
|
+
|
|
158
|
+
artifacts:
|
|
159
|
+
when: always
|
|
160
|
+
paths:
|
|
161
|
+
- examples/uat/playwright-report
|
|
162
|
+
|
|
163
|
+
uat-multiactor:
|
|
164
|
+
stage: uat
|
|
165
|
+
script:
|
|
166
|
+
- cd examples
|
|
167
|
+
- npm install $(npm pack ../../testing-framework | tail -1)
|
|
168
|
+
- output=$(npm run uat-multiactor)
|
|
169
|
+
- echo "$output"
|
|
170
|
+
- node ../ValidateUATReport.js examples
|
|
171
|
+
|
|
172
|
+
artifacts:
|
|
173
|
+
when: always
|
|
174
|
+
paths:
|
|
175
|
+
- examples/uat/playwright-report
|
|
176
|
+
|
|
177
|
+
uat-data_generator:
|
|
178
|
+
stage: uat
|
|
179
|
+
script:
|
|
180
|
+
- cd examples
|
|
181
|
+
- npm install $(npm pack ../../testing-framework | tail -1)
|
|
182
|
+
- output=$(npm run uat-data_generator)
|
|
183
|
+
- echo "$output"
|
|
184
|
+
- node ../ValidateUATReport.js examples
|
|
185
|
+
|
|
186
|
+
artifacts:
|
|
187
|
+
when: always
|
|
188
|
+
paths:
|
|
189
|
+
- examples/uat/playwright-report
|
|
190
|
+
|
|
191
|
+
|
package/README.md
CHANGED
|
@@ -12,7 +12,157 @@
|
|
|
12
12
|
### Run TestCase
|
|
13
13
|
|
|
14
14
|
- npm run test
|
|
15
|
+
|
|
15
16
|
### Generate Report
|
|
16
17
|
|
|
17
18
|
- npm run report
|
|
18
|
-
|
|
19
|
+
|
|
20
|
+
## Version History
|
|
21
|
+
|
|
22
|
+
### v3.2.8 - 18-09-2025
|
|
23
|
+
|
|
24
|
+
### Bug fix
|
|
25
|
+
|
|
26
|
+
- Default profile switching handled in Multi actor – Improved handling of default profile switching to ensure smoother execution flow.
|
|
27
|
+
|
|
28
|
+
- QC Report tags issue fixed – Resolved an issue where QC Report tags were not displaying correctly in reports.
|
|
29
|
+
|
|
30
|
+
### v3.2.7 - 10-09-2025
|
|
31
|
+
|
|
32
|
+
### Bug fix
|
|
33
|
+
- Fixed a bug where the default profile page was not being handled properly in `this`.
|
|
34
|
+
|
|
35
|
+
### v3.2.6 - 05-09-2025
|
|
36
|
+
|
|
37
|
+
#### Feature
|
|
38
|
+
|
|
39
|
+
- Multi-actor execution support – now possible to switch between multiple profile agents within scenarios using the predefined step: - `access the {string} profile page`
|
|
40
|
+
|
|
41
|
+
### Bug fix
|
|
42
|
+
- Fixed the issue where localapp and hcapp UAT were not running properly.
|
|
43
|
+
|
|
44
|
+
### v3.2.5 - 28-08-2025
|
|
45
|
+
|
|
46
|
+
#### Enhancement
|
|
47
|
+
|
|
48
|
+
- Removed the searchFake dependency from the project level and adopted it inside the framework, reducing project-side maintenance. use this predefined step: - `Given (a search entity)`
|
|
49
|
+
|
|
50
|
+
### v3.2.4 - 29-07-2025
|
|
51
|
+
|
|
52
|
+
#### Feature
|
|
53
|
+
- Data Generator steps are now supported directly via the framework.
|
|
54
|
+
|
|
55
|
+
### Bug fix
|
|
56
|
+
- Feature File Root Directory not found issue fixed
|
|
57
|
+
|
|
58
|
+
### v3.2.3 - 29-07-2025
|
|
59
|
+
|
|
60
|
+
#### Feature
|
|
61
|
+
- Added support for running Smoke Tests in the UAT stage.
|
|
62
|
+
|
|
63
|
+
### v3.2.0 - 22-06-2025
|
|
64
|
+
|
|
65
|
+
#### Feature
|
|
66
|
+
- Default required spec files are now auto-imported from the library into the project.
|
|
67
|
+
|
|
68
|
+
### v3.1.13 - 02-07-2025
|
|
69
|
+
|
|
70
|
+
#### Enhancement
|
|
71
|
+
- Below package versions are updated in this release.
|
|
72
|
+
- @cucumber/Cucumber - 11.3.0
|
|
73
|
+
- Playwright/test - 1.53.2
|
|
74
|
+
- Playwright - 1.53.2
|
|
75
|
+
- Playwright-bdd - 8.3.1
|
|
76
|
+
- QC custom reporter changes have been adopted into the framework.
|
|
77
|
+
|
|
78
|
+
### v3.1.5 - 22-05-2025
|
|
79
|
+
|
|
80
|
+
#### Feature
|
|
81
|
+
- Added support for Module Based Execution UAT stage.
|
|
82
|
+
|
|
83
|
+
### v3.1.4 - 12-05-2025
|
|
84
|
+
|
|
85
|
+
#### Enhancement
|
|
86
|
+
- Playwright version 1.52.0 adopted in testing framework
|
|
87
|
+
|
|
88
|
+
### v3.1.3 - 25-04-2025
|
|
89
|
+
|
|
90
|
+
#### Enhancement
|
|
91
|
+
- Playwright version 1.51.0 adopted in testing framework
|
|
92
|
+
|
|
93
|
+
### v0.2.8 - 26-09-2024
|
|
94
|
+
|
|
95
|
+
#### Feature
|
|
96
|
+
- Added support for writing unitcases for framework implementations
|
|
97
|
+
|
|
98
|
+
### Bug fix
|
|
99
|
+
- Updated the custom-reported to include the errors in tests during the executions. It will help us avoid the stage passed without the actual test execution.
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
### v3.0.8 - 25-12-2024
|
|
103
|
+
|
|
104
|
+
#### Enhancement
|
|
105
|
+
- Added support to disable headless mode using command line arguments
|
|
106
|
+
- Proper validation added for node 14 build process
|
|
107
|
+
- Removed unwanted uat.config.js files in test projects (examples / nobdd)
|
|
108
|
+
|
|
109
|
+
### v0.2.9.2 - 22-11-2024
|
|
110
|
+
|
|
111
|
+
#### BugFix
|
|
112
|
+
- Implemented synchronization for the login process. This fix will help avoid login session-related failures in UAT.
|
|
113
|
+
|
|
114
|
+
### v0.3.1 - 13-11-2024
|
|
115
|
+
|
|
116
|
+
#### Issue Fix
|
|
117
|
+
- Adding bddmode to get the fixtures.
|
|
118
|
+
|
|
119
|
+
### v0.2.9.1 - 14-11-2024
|
|
120
|
+
|
|
121
|
+
#### Enhancement
|
|
122
|
+
- Beta feature Actors and edition configurations are unified
|
|
123
|
+
|
|
124
|
+
### v0.2.9 - 25-10-2024
|
|
125
|
+
|
|
126
|
+
#### Feature
|
|
127
|
+
- Added support for scenario level tag support
|
|
128
|
+
- Added a new cli optin like uat-validate to validate the feature files using playwright-bdd
|
|
129
|
+
- Mode based configuration implementations
|
|
130
|
+
- @only option enabled in dev pipeline
|
|
131
|
+
- Latest setup related configuration changed for init option
|
|
132
|
+
|
|
133
|
+
### v0.3.0 - 25-10-2024
|
|
134
|
+
|
|
135
|
+
#### Features
|
|
136
|
+
- Added support for scenario level tag support
|
|
137
|
+
- Updated the configuration for `video` and `trace` to accept Playwright-specific values instead of boolean values.
|
|
138
|
+
- Below package versions are updated in this release.
|
|
139
|
+
- playwright - 1.48.0,
|
|
140
|
+
- playwright-bdd - 7.5.0,
|
|
141
|
+
- @playwright/test - 1.48.0,
|
|
142
|
+
- @cucumber/cucumber - 11.0.1
|
|
143
|
+
- From this version, We adopt the playwright-bdd as library instead of modified source
|
|
144
|
+
- Published on 11-11-2024
|
|
145
|
+
|
|
146
|
+
#### Deprecations
|
|
147
|
+
- **Deprecated**: Passing `video` and `trace` as boolean (`true`/`false`) in project configuration.
|
|
148
|
+
- **New Approach**: Use Playwright values for `video` and `trace` options, such as `'on'`, `'retain-on-failure'`, or `'off'`.
|
|
149
|
+
|
|
150
|
+
### v0.3.1 - 13-11-2024
|
|
151
|
+
|
|
152
|
+
#### Issue Fix
|
|
153
|
+
- Adding bddmode to get the fixtures.
|
|
154
|
+
|
|
155
|
+
### v0.3.3 - 27-11-2024
|
|
156
|
+
|
|
157
|
+
#### Feature
|
|
158
|
+
- Custom report integration support (ReportPortal)
|
|
159
|
+
|
|
160
|
+
### v0.2.9.1 - 14-11-2024
|
|
161
|
+
|
|
162
|
+
#### Enhancement
|
|
163
|
+
- Beta feature Actors and edition configurations are unified
|
|
164
|
+
|
|
165
|
+
### v0.2.9.2 - 22-11-2024
|
|
166
|
+
|
|
167
|
+
#### BugFix
|
|
168
|
+
- Implemented synchronization for the login process. This fix will help avoid login session-related failures in UAT.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { createBdd , test } from '@zohodesk/testinglibrary';
|
|
2
|
+
import { generateAndCacheTestData } from './DataGeneratorStepsHelper';
|
|
3
|
+
|
|
4
|
+
const { Given } = createBdd();
|
|
5
|
+
|
|
6
|
+
Given('generate a {string} entity {string} with generator {string}', async ({ page, context, i18N, cacheLayer, executionContext}, module, entityName, generatorName, dataTable) => {
|
|
7
|
+
await generateAndCacheTestData(executionContext, "template", generatorName, dataTable, cacheLayer, entityName);
|
|
8
|
+
});
|
|
9
|
+
|
|
10
|
+
Given('generate a {string} entity {string} with API {string}', async ({ page, context, i18N, cacheLayer, executionContext}, module, entityName, operationId, dataTable) => {
|
|
11
|
+
await generateAndCacheTestData(executionContext, "API", operationId, dataTable, cacheLayer, entityName);
|
|
12
|
+
});
|
|
13
|
+
Given('generate a {string} entity {string} with generator {string} using {string} profile', async ({ page, context, i18N, cacheLayer, executionContext}, module, entityName, generatorName, profile, dataTable) => {
|
|
14
|
+
await generateAndCacheTestData(executionContext, "template", generatorName, dataTable, cacheLayer, entityName, profile);
|
|
15
|
+
});
|
|
16
|
+
|
|
17
|
+
Given('generate a {string} entity {string} with API {string} using {string} profile', async ({ page, context, i18N, cacheLayer, executionContext}, module, entityName, operationId, profile, dataTable) => {
|
|
18
|
+
await generateAndCacheTestData(executionContext, "API", operationId, dataTable, cacheLayer, entityName, profile);
|
|
19
|
+
});
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { test } from '@zohodesk/testinglibrary';
|
|
2
|
+
import DataGenerator from '@zohodesk/testinglibrary/DataGenerator';
|
|
3
|
+
|
|
4
|
+
const dataGenerator = new DataGenerator();
|
|
5
|
+
|
|
6
|
+
export async function generateAndCacheTestData(executionContext, type, identifier, dataTable, cacheLayer, entityName, profile = null) {
|
|
7
|
+
let actorInfo;
|
|
8
|
+
const testInfo = test.info();
|
|
9
|
+
const scenarioName = testInfo.title.split('/').pop() || 'Unknown Scenario';
|
|
10
|
+
|
|
11
|
+
if (profile) {
|
|
12
|
+
actorInfo = await dataGenerator.getDataGenUserExecutionContext(executionContext.actorInfo.edition, profile);
|
|
13
|
+
} else {
|
|
14
|
+
actorInfo = executionContext.actorInfo;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
const generatedData = await dataGenerator.generate(testInfo, actorInfo, type, identifier, scenarioName, dataTable ? dataTable.hashes() : []);
|
|
18
|
+
await cacheLayer.set(entityName, generatedData.data);
|
|
19
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { createBdd } from '@zohodesk/testinglibrary';
|
|
2
|
+
const { BeforeScenario, Given } = createBdd();
|
|
3
|
+
|
|
4
|
+
BeforeScenario(async function({ page, context, browser, cacheLayer, executionContext, actorContext }) {
|
|
5
|
+
// This will run before each scenario and set all the fixtures into this context
|
|
6
|
+
this.page = page;
|
|
7
|
+
this.context = context;
|
|
8
|
+
this.browser = browser;
|
|
9
|
+
this.cacheLayer = cacheLayer;
|
|
10
|
+
this.executionContext = executionContext;
|
|
11
|
+
this.setActor = async (role) => {
|
|
12
|
+
const userPage = actorContext.actorsObj[role];
|
|
13
|
+
if (userPage) {
|
|
14
|
+
this.page = userPage.page;
|
|
15
|
+
this.context = userPage.context;
|
|
16
|
+
this.browser = userPage.browser;
|
|
17
|
+
this.executionContext = userPage.executionContext;
|
|
18
|
+
} else {
|
|
19
|
+
throw new Error(`Actor "${role}" not found in user pages.`);
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
});
|
|
23
|
+
|
|
24
|
+
Given("access the {string} profile page", async function({ page }, userRole) {
|
|
25
|
+
await this.setActor(userRole);
|
|
26
|
+
});
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { expect } from '@zohodesk/testinglibrary';
|
|
2
|
+
|
|
3
|
+
async function executeRpcRequest(page, payload) {
|
|
4
|
+
|
|
5
|
+
const url = new URL(page.url());
|
|
6
|
+
const baseUrl = `${url.protocol}//${url.host}`;
|
|
7
|
+
const invokeURL = `${baseUrl}/api/testing/acceptanceTest/rpc/invoke`;
|
|
8
|
+
|
|
9
|
+
try {
|
|
10
|
+
const response = await page.request.post(invokeURL, {
|
|
11
|
+
headers: {'Content-Type': 'application/json'},
|
|
12
|
+
data: payload
|
|
13
|
+
});
|
|
14
|
+
|
|
15
|
+
if (!response.ok()) {
|
|
16
|
+
throw new Error(`HTTP ${response.status()}: ${response.statusText()}`);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
const responseData = await response.json();
|
|
20
|
+
expect(responseData.data).toHaveProperty('status', 'success');
|
|
21
|
+
|
|
22
|
+
} catch (error) {
|
|
23
|
+
throw error;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
async function entityIdReConstructor(payload) {
|
|
29
|
+
|
|
30
|
+
if (typeof payload !== 'object' || payload === null) {
|
|
31
|
+
throw new Error('Invalid payload. It must be a non-null object.');
|
|
32
|
+
}
|
|
33
|
+
if (!payload.arguments || typeof payload.arguments.entityId !== 'string') {
|
|
34
|
+
throw new Error('Invalid payload.arguments.entityId. It must be a non-empty string.');
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
payload.arguments.entityId = payload.arguments.entityId.split(',').map(id => id.trim());
|
|
38
|
+
return payload;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
module.exports = { executeRpcRequest, entityIdReConstructor };
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import {createBdd } from '@zohodesk/testinglibrary';
|
|
2
|
+
import { executeRpcRequest , entityIdReConstructor } from '../helpers/rpcRequestHelper';
|
|
3
|
+
|
|
4
|
+
const { Given } = createBdd();
|
|
5
|
+
|
|
6
|
+
Given('a search entity', async ({page}, dataTable)=>{
|
|
7
|
+
const data = dataTable.hashes();
|
|
8
|
+
|
|
9
|
+
for (const row of data) {
|
|
10
|
+
|
|
11
|
+
const { moduleName, entityId, searchString } = row;
|
|
12
|
+
const payload = {
|
|
13
|
+
className: 'applicationDriver.rpc.desk.integrations.search.SearchFakeDataPopulator',
|
|
14
|
+
methodName: 'populateSearchData',
|
|
15
|
+
arguments: {
|
|
16
|
+
module: moduleName,
|
|
17
|
+
searchString: searchString,
|
|
18
|
+
entityId: entityId
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
await entityIdReConstructor(payload);
|
|
22
|
+
|
|
23
|
+
await executeRpcRequest(page, payload);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
});
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.default = void 0;
|
|
8
|
+
var _path = _interopRequireDefault(require("path"));
|
|
9
|
+
var _fs = _interopRequireDefault(require("fs"));
|
|
10
|
+
var _logger = require("../../utils/logger");
|
|
11
|
+
var _DataGeneratorHelper = require("./DataGeneratorHelper");
|
|
12
|
+
var _helpers = require("@zohodesk/testinglibrary/helpers");
|
|
13
|
+
var _DataGeneratorError = require("./DataGeneratorError");
|
|
14
|
+
function _classPrivateMethodInitSpec(e, a) { _checkPrivateRedeclaration(e, a), a.add(e); }
|
|
15
|
+
function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
|
|
16
|
+
function _assertClassBrand(e, t, n) { if ("function" == typeof e ? e === t : e.has(t)) return arguments.length < 3 ? t : n; throw new TypeError("Private element is not present on this object"); }
|
|
17
|
+
var _DataGenerator_brand = /*#__PURE__*/new WeakSet();
|
|
18
|
+
class DataGenerator {
|
|
19
|
+
constructor() {
|
|
20
|
+
_classPrivateMethodInitSpec(this, _DataGenerator_brand);
|
|
21
|
+
}
|
|
22
|
+
async generate(testInfo, actorInfo, generatorType, generatorName, scenarioName, dataTable) {
|
|
23
|
+
try {
|
|
24
|
+
let generators;
|
|
25
|
+
if (generatorType === 'API') {
|
|
26
|
+
generators = await _assertClassBrand(_DataGenerator_brand, this, _generateAPIGenerator).call(this, generatorName);
|
|
27
|
+
} else {
|
|
28
|
+
generators = await _assertClassBrand(_DataGenerator_brand, this, _getGenerator).call(this, testInfo, generatorName);
|
|
29
|
+
}
|
|
30
|
+
const processedGenerators = await (0, _DataGeneratorHelper.processGenerator)(generators, dataTable);
|
|
31
|
+
const apiPayload = await _assertClassBrand(_DataGenerator_brand, this, _constructApiPayload).call(this, scenarioName, processedGenerators, actorInfo);
|
|
32
|
+
const response = await (0, _DataGeneratorHelper.makeRequest)(process.env.DG_SERVICE_DOMAIN + process.env.DG_SERVICE_API_PATH, apiPayload);
|
|
33
|
+
_logger.Logger.log(_logger.Logger.INFO_TYPE, `Generated response for the generator: ${generatorName} for scenario: ${scenarioName}, Response: ${JSON.stringify(response)}`);
|
|
34
|
+
return response;
|
|
35
|
+
} catch (error) {
|
|
36
|
+
if (error instanceof _DataGeneratorError.DataGeneratorError) {
|
|
37
|
+
console.error(error.getMessage());
|
|
38
|
+
console.error("Stack trace:", error.stack);
|
|
39
|
+
_logger.Logger.log(_logger.Logger.FAILURE_TYPE, error.getMessage());
|
|
40
|
+
} else {
|
|
41
|
+
console.error("Error Type:", error.constructor.name);
|
|
42
|
+
console.error("Error Message:", error.message);
|
|
43
|
+
console.error("Stack trace:", error.stack);
|
|
44
|
+
_logger.Logger.log(_logger.Logger.FAILURE_TYPE, `${error.constructor.name} - Message: ${error.message}`);
|
|
45
|
+
}
|
|
46
|
+
console.error('Data Generation failed for the generator: ', generatorName, "\n\nError response :", error);
|
|
47
|
+
throw error;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
async getDataGenUserExecutionContext(edition, profile) {
|
|
51
|
+
try {
|
|
52
|
+
const dataGenUserDetails = await (0, _helpers.getUserForSelectedEditionAndProfile)(edition, profile);
|
|
53
|
+
return dataGenUserDetails;
|
|
54
|
+
} catch (error) {
|
|
55
|
+
console.error('Error occurred while fetching data generation user details: ', error);
|
|
56
|
+
throw error;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
async function _getGenerator(testInfo, generatorName) {
|
|
61
|
+
let generator = null;
|
|
62
|
+
let generatorFilePath = await (0, _DataGeneratorHelper.getGeneratorFilePath)(testInfo.file);
|
|
63
|
+
generatorFilePath = _path.default.join(generatorFilePath, "../../data-generators/generators.json");
|
|
64
|
+
if (_fs.default.existsSync(generatorFilePath)) {
|
|
65
|
+
const data = _fs.default.readFileSync(generatorFilePath, 'utf8');
|
|
66
|
+
const generatorObj = JSON.parse(data);
|
|
67
|
+
if (generatorName || generatorObj.generators) {
|
|
68
|
+
generator = generatorObj.generators[generatorName] || null;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
if (!generator) {
|
|
72
|
+
throw new _DataGeneratorError.GeneratorError(`Generator "${generatorName}" could not be found in the path located at "${generatorFilePath}"`);
|
|
73
|
+
}
|
|
74
|
+
return generator;
|
|
75
|
+
}
|
|
76
|
+
async function _generateAPIGenerator(operationId) {
|
|
77
|
+
return [{
|
|
78
|
+
type: "dynamic",
|
|
79
|
+
generatorOperationId: operationId,
|
|
80
|
+
dataPath: "$.response.body:$",
|
|
81
|
+
name: operationId
|
|
82
|
+
}];
|
|
83
|
+
}
|
|
84
|
+
async function _constructApiPayload(scenarioName, processedGenerators, actorInfo) {
|
|
85
|
+
const dataGeneratorObj = actorInfo['data-generator'];
|
|
86
|
+
if (!dataGeneratorObj) {
|
|
87
|
+
throw new _DataGeneratorError.DataGeneratorConfigurationError(`Data Generator configuration is missing for the profile: ${actorInfo['profile']}`);
|
|
88
|
+
}
|
|
89
|
+
const apiPayload = {
|
|
90
|
+
scenario_name: scenarioName,
|
|
91
|
+
data_generation_templates: processedGenerators,
|
|
92
|
+
...dataGeneratorObj
|
|
93
|
+
};
|
|
94
|
+
const account = apiPayload.account;
|
|
95
|
+
if (account) {
|
|
96
|
+
account.email = actorInfo.email;
|
|
97
|
+
account.password = actorInfo.password;
|
|
98
|
+
}
|
|
99
|
+
const environmentDetails = apiPayload.environmentDetails || {};
|
|
100
|
+
if (environmentDetails) {
|
|
101
|
+
environmentDetails.iam_url = process.env.DG_IAM_DOMAIN;
|
|
102
|
+
const domainUrl = new URL(process.env.domain);
|
|
103
|
+
environmentDetails.host = domainUrl.origin;
|
|
104
|
+
}
|
|
105
|
+
apiPayload.environmentDetails = environmentDetails;
|
|
106
|
+
return apiPayload;
|
|
107
|
+
}
|
|
108
|
+
var _default = exports.default = DataGenerator;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.GeneratorError = exports.DataGeneratorError = exports.DataGeneratorConfigurationError = void 0;
|
|
7
|
+
class DataGeneratorError extends Error {
|
|
8
|
+
constructor(message) {
|
|
9
|
+
super(message);
|
|
10
|
+
this.name = 'DataGeneratorError';
|
|
11
|
+
|
|
12
|
+
// Maintains proper stack trace for where our error was thrown (only available on V8)
|
|
13
|
+
if (Error.captureStackTrace) {
|
|
14
|
+
Error.captureStackTrace(this, DataGeneratorError);
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* Get formatted error message with error type and message
|
|
20
|
+
* @returns {string} Formatted error message
|
|
21
|
+
*/
|
|
22
|
+
getMessage() {
|
|
23
|
+
return `\n\n ${this.name} ::: \n\n Error Message: ${this.message} \n\n `;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
// Specific error for Data Generator configuration issues
|
|
28
|
+
exports.DataGeneratorError = DataGeneratorError;
|
|
29
|
+
class DataGeneratorConfigurationError extends DataGeneratorError {
|
|
30
|
+
constructor(message) {
|
|
31
|
+
super(message);
|
|
32
|
+
this.name = 'DataGeneratorConfigurationError';
|
|
33
|
+
if (Error.captureStackTrace) {
|
|
34
|
+
Error.captureStackTrace(this, DataGeneratorConfigurationError);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
// Specific error for Generator related issues
|
|
40
|
+
exports.DataGeneratorConfigurationError = DataGeneratorConfigurationError;
|
|
41
|
+
class GeneratorError extends DataGeneratorError {
|
|
42
|
+
constructor(message) {
|
|
43
|
+
super(message);
|
|
44
|
+
this.name = 'GeneratorError';
|
|
45
|
+
if (Error.captureStackTrace) {
|
|
46
|
+
Error.captureStackTrace(this, GeneratorError);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
exports.GeneratorError = GeneratorError;
|