dceky 1.0.0-beta.6 → 1.0.2

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.
Files changed (199) hide show
  1. package/.eslintrc.js +93 -0
  2. package/README.md +41 -0
  3. package/cypress/e2e/profile-test.cy.ts +10 -0
  4. package/cypress/fixtures/example.json +5 -0
  5. package/cypress/support/commands.ts +37 -0
  6. package/cypress/support/e2e.ts +17 -0
  7. package/cypress.config.ts +9 -0
  8. package/docs/GlobalsAndProfiles.md +23 -0
  9. package/lib/setup/addToGitIgnore.d.ts +6 -0
  10. package/lib/setup/addToGitIgnore.js +46 -0
  11. package/lib/setup/addToGitIgnore.js.map +1 -0
  12. package/lib/setup/checkRequiredFiles.d.ts +6 -0
  13. package/lib/setup/checkRequiredFiles.js +58 -0
  14. package/lib/setup/checkRequiredFiles.js.map +1 -0
  15. package/lib/setup/genCommandImportFile.d.ts +7 -0
  16. package/lib/setup/genCommandImportFile.js +66 -0
  17. package/lib/setup/genCommandImportFile.js.map +1 -0
  18. package/lib/setup/genConfiguration/helpers/resolveDependents.d.ts +13 -0
  19. package/lib/setup/genConfiguration/helpers/resolveDependents.js +50 -0
  20. package/lib/setup/genConfiguration/helpers/resolveDependents.js.map +1 -0
  21. package/lib/setup/genConfiguration/helpers/splitEnv.d.ts +10 -0
  22. package/lib/setup/genConfiguration/helpers/splitEnv.js +27 -0
  23. package/lib/setup/genConfiguration/helpers/splitEnv.js.map +1 -0
  24. package/lib/setup/genConfiguration/index.d.ts +15 -0
  25. package/lib/setup/genConfiguration/index.js +86 -0
  26. package/lib/setup/genConfiguration/index.js.map +1 -0
  27. package/lib/setup/genConfiguration/types/DependentValue.d.ts +11 -0
  28. package/lib/setup/genConfiguration/types/DependentValue.js +3 -0
  29. package/lib/setup/genConfiguration/types/DependentValue.js.map +1 -0
  30. package/lib/setup/genConfiguration/types/GlobalsOrProfile.d.ts +9 -0
  31. package/lib/setup/genConfiguration/types/GlobalsOrProfile.js +3 -0
  32. package/lib/setup/genConfiguration/types/GlobalsOrProfile.js.map +1 -0
  33. package/lib/setup/genConfiguration/types/SplitEnv.d.ts +13 -0
  34. package/lib/setup/genConfiguration/types/SplitEnv.js +3 -0
  35. package/lib/setup/genConfiguration/types/SplitEnv.js.map +1 -0
  36. package/lib/setup/genConfigurationFile.d.ts +2 -0
  37. package/lib/setup/genConfigurationFile.js +63 -0
  38. package/lib/setup/genConfigurationFile.js.map +1 -0
  39. package/lib/setup/genDynamicConfigFile.d.ts +5 -0
  40. package/lib/setup/genDynamicConfigFile.js +28 -0
  41. package/lib/setup/genDynamicConfigFile.js.map +1 -0
  42. package/lib/setup/index.d.ts +1 -0
  43. package/lib/setup/index.js +16 -0
  44. package/lib/setup/index.js.map +1 -0
  45. package/lib/setup/setupCypressDependencies.d.ts +6 -0
  46. package/lib/setup/setupCypressDependencies.js +40 -0
  47. package/lib/setup/setupCypressDependencies.js.map +1 -0
  48. package/lib/src/commands/assertDoesNotHaveClass.d.ts +20 -0
  49. package/lib/src/commands/assertDoesNotHaveClass.js +17 -0
  50. package/lib/src/commands/assertDoesNotHaveClass.js.map +1 -0
  51. package/lib/src/commands/assertHasClass.d.ts +20 -0
  52. package/lib/src/commands/assertHasClass.js +17 -0
  53. package/lib/src/commands/assertHasClass.js.map +1 -0
  54. package/lib/src/commands/assertNumElements.d.ts +19 -0
  55. package/lib/src/commands/assertNumElements.js +17 -0
  56. package/lib/src/commands/assertNumElements.js.map +1 -0
  57. package/lib/src/commands/extractDataFromClass.d.ts +18 -0
  58. package/lib/src/commands/extractDataFromClass.js +25 -0
  59. package/lib/src/commands/extractDataFromClass.js.map +1 -0
  60. package/lib/src/commands/extractDataFromClassByContents.d.ts +19 -0
  61. package/lib/src/commands/extractDataFromClassByContents.js +26 -0
  62. package/lib/src/commands/extractDataFromClassByContents.js.map +1 -0
  63. package/lib/src/commands/getJSON.d.ts +16 -0
  64. package/lib/src/commands/getJSON.js +21 -0
  65. package/lib/src/commands/getJSON.js.map +1 -0
  66. package/lib/src/commands/getNumElements.d.ts +15 -0
  67. package/lib/src/commands/getNumElements.js +19 -0
  68. package/lib/src/commands/getNumElements.js.map +1 -0
  69. package/lib/src/commands/handleHarvardKey.d.ts +15 -0
  70. package/lib/src/commands/handleHarvardKey.js +53 -0
  71. package/lib/src/commands/handleHarvardKey.js.map +1 -0
  72. package/lib/src/commands/launchAs.d.ts +25 -0
  73. package/lib/src/commands/launchAs.js +66 -0
  74. package/lib/src/commands/launchAs.js.map +1 -0
  75. package/lib/src/commands/launchLTIUsingToken.d.ts +21 -0
  76. package/lib/src/commands/launchLTIUsingToken.js +68 -0
  77. package/lib/src/commands/launchLTIUsingToken.js.map +1 -0
  78. package/lib/src/commands/navigateToHref.d.ts +15 -0
  79. package/lib/src/commands/navigateToHref.js +35 -0
  80. package/lib/src/commands/navigateToHref.js.map +1 -0
  81. package/lib/src/commands/runScript.d.ts +15 -0
  82. package/lib/src/commands/runScript.js +20 -0
  83. package/lib/src/commands/runScript.js.map +1 -0
  84. package/lib/src/commands/typeInto.d.ts +24 -0
  85. package/lib/src/commands/typeInto.js +41 -0
  86. package/lib/src/commands/typeInto.js.map +1 -0
  87. package/lib/src/commands/visitCanvasGETEndpoint.d.ts +20 -0
  88. package/lib/src/commands/visitCanvasGETEndpoint.js +26 -0
  89. package/lib/src/commands/visitCanvasGETEndpoint.js.map +1 -0
  90. package/lib/src/commands/waitForElementVisible.d.ts +16 -0
  91. package/lib/src/commands/waitForElementVisible.js +19 -0
  92. package/lib/src/commands/waitForElementVisible.js.map +1 -0
  93. package/lib/src/genConfiguration/helpers/resolveDependents.d.ts +13 -0
  94. package/lib/src/genConfiguration/helpers/resolveDependents.js +50 -0
  95. package/lib/src/genConfiguration/helpers/resolveDependents.js.map +1 -0
  96. package/lib/src/genConfiguration/helpers/splitEnv.d.ts +10 -0
  97. package/lib/src/genConfiguration/helpers/splitEnv.js +27 -0
  98. package/lib/src/genConfiguration/helpers/splitEnv.js.map +1 -0
  99. package/{src/genConfiguration.ts → lib/src/genConfiguration/index.d.ts} +3 -6
  100. package/lib/src/genConfiguration/index.js +88 -0
  101. package/lib/src/genConfiguration/index.js.map +1 -0
  102. package/lib/src/genConfiguration/types/DependentValue.d.ts +11 -0
  103. package/lib/src/genConfiguration/types/DependentValue.js +3 -0
  104. package/lib/src/genConfiguration/types/DependentValue.js.map +1 -0
  105. package/lib/src/genConfiguration/types/GlobalsOrProfile.d.ts +9 -0
  106. package/lib/src/genConfiguration/types/GlobalsOrProfile.js +3 -0
  107. package/lib/src/genConfiguration/types/GlobalsOrProfile.js.map +1 -0
  108. package/lib/src/genConfiguration/types/SplitEnv.d.ts +13 -0
  109. package/lib/src/genConfiguration/types/SplitEnv.js +3 -0
  110. package/lib/src/genConfiguration/types/SplitEnv.js.map +1 -0
  111. package/lib/{index.d.ts → src/index.d.ts} +1 -1
  112. package/lib/{index.js → src/index.js} +6 -3
  113. package/lib/src/index.js.map +1 -0
  114. package/lib/src/init.d.ts +6 -0
  115. package/lib/src/init.js +45 -0
  116. package/lib/src/init.js.map +1 -0
  117. package/lib/start/constants/AVAILABLE_BROWSERS.d.ts +9 -0
  118. package/lib/start/constants/AVAILABLE_BROWSERS.js +27 -0
  119. package/lib/start/constants/AVAILABLE_BROWSERS.js.map +1 -0
  120. package/lib/start/helpers/exec.d.ts +8 -0
  121. package/lib/start/helpers/exec.js +18 -0
  122. package/lib/start/helpers/exec.js.map +1 -0
  123. package/lib/start/helpers/extractArgValue.d.ts +10 -0
  124. package/lib/start/helpers/extractArgValue.js +39 -0
  125. package/lib/start/helpers/extractArgValue.js.map +1 -0
  126. package/lib/start/helpers/findProfilesByNames.d.ts +16 -0
  127. package/lib/start/helpers/findProfilesByNames.js +35 -0
  128. package/lib/start/helpers/findProfilesByNames.js.map +1 -0
  129. package/lib/start/helpers/parseCommaSeparated.d.ts +8 -0
  130. package/lib/start/helpers/parseCommaSeparated.js +23 -0
  131. package/lib/start/helpers/parseCommaSeparated.js.map +1 -0
  132. package/lib/start/helpers/print.d.ts +38 -0
  133. package/lib/start/helpers/print.js +145 -0
  134. package/lib/start/helpers/print.js.map +1 -0
  135. package/lib/start/helpers/prompt.d.ts +8 -0
  136. package/lib/start/helpers/prompt.js +25 -0
  137. package/lib/start/helpers/prompt.js.map +1 -0
  138. package/lib/start/helpers/showChooser.d.ts +21 -0
  139. package/lib/start/helpers/showChooser.js +116 -0
  140. package/lib/start/helpers/showChooser.js.map +1 -0
  141. package/lib/start/helpers/validateBrowsers.d.ts +8 -0
  142. package/lib/start/helpers/validateBrowsers.js +36 -0
  143. package/lib/start/helpers/validateBrowsers.js.map +1 -0
  144. package/lib/start/index.d.ts +7 -0
  145. package/lib/start/index.js +139 -0
  146. package/lib/start/index.js.map +1 -0
  147. package/lib/start/types/ChooserOption.d.ts +10 -0
  148. package/lib/start/types/ChooserOption.js +3 -0
  149. package/lib/start/types/ChooserOption.js.map +1 -0
  150. package/package.json +28 -8
  151. package/setup/addToGitIgnore.ts +47 -0
  152. package/setup/checkRequiredFiles.ts +62 -0
  153. package/setup/genCommandImportFile.ts +75 -0
  154. package/setup/genDynamicConfigFile.ts +28 -0
  155. package/setup/index.ts +11 -0
  156. package/setup/setupCypressDependencies.ts +38 -0
  157. package/src/commands/assertDoesNotHaveClass.ts +51 -0
  158. package/src/commands/assertHasClass.ts +51 -0
  159. package/src/commands/assertNumElements.ts +50 -0
  160. package/src/commands/extractDataFromClass.ts +52 -0
  161. package/src/commands/extractDataFromClassByContents.ts +55 -0
  162. package/src/commands/getJSON.ts +45 -0
  163. package/src/commands/getNumElements.ts +45 -0
  164. package/src/commands/handleHarvardKey.ts +91 -0
  165. package/src/commands/launchAs.ts +120 -0
  166. package/src/commands/launchLTIUsingToken.ts +115 -0
  167. package/src/commands/navigateToHref.ts +60 -0
  168. package/src/commands/runScript.ts +44 -0
  169. package/src/commands/typeInto.ts +88 -0
  170. package/src/commands/visitCanvasGETEndpoint.ts +61 -0
  171. package/src/commands/waitForElementVisible.ts +49 -0
  172. package/src/genConfiguration/helpers/resolveDependents.ts +47 -0
  173. package/src/genConfiguration/helpers/splitEnv.ts +30 -0
  174. package/src/genConfiguration/index.ts +94 -0
  175. package/src/genConfiguration/types/DependentValue.ts +14 -0
  176. package/src/genConfiguration/types/GlobalsOrProfile.ts +12 -0
  177. package/src/genConfiguration/types/SplitEnv.ts +18 -0
  178. package/src/index.ts +7 -4
  179. package/src/init.ts +36 -17
  180. package/start/constants/AVAILABLE_BROWSERS.ts +28 -0
  181. package/start/helpers/exec.ts +17 -0
  182. package/start/helpers/extractArgValue.ts +42 -0
  183. package/start/helpers/findProfilesByNames.ts +39 -0
  184. package/start/helpers/parseCommaSeparated.ts +23 -0
  185. package/start/helpers/print.ts +155 -0
  186. package/start/helpers/prompt.ts +23 -0
  187. package/start/helpers/showChooser.ts +140 -0
  188. package/start/helpers/validateBrowsers.ts +35 -0
  189. package/start/index.ts +163 -0
  190. package/start/types/ChooserOption.ts +11 -0
  191. package/tsconfig.json +3 -4
  192. package/.eslintrc.json +0 -58
  193. package/lib/genConfiguration.d.ts +0 -8
  194. package/lib/genConfiguration.js +0 -13
  195. package/lib/genConfiguration.js.map +0 -1
  196. package/lib/index.js.map +0 -1
  197. package/lib/init.d.ts +0 -13
  198. package/lib/init.js +0 -10
  199. package/lib/init.js.map +0 -1
package/.eslintrc.js ADDED
@@ -0,0 +1,93 @@
1
+ const config = {
2
+ extends: [
3
+ 'airbnb',
4
+ 'airbnb/hooks',
5
+ ],
6
+ overrides: [
7
+ {
8
+ files: [
9
+ '*.ts',
10
+ '*.tsx',
11
+ ],
12
+ extends: [
13
+ 'airbnb-typescript',
14
+ ],
15
+ parserOptions: {
16
+ project: './tsconfig.json',
17
+ tsconfigRootDir: __dirname,
18
+ sourceType: 'module',
19
+ },
20
+ rules: {
21
+ '@typescript-eslint/lines-between-class-members': 'off',
22
+ '@typescript-eslint/no-unused-expressions': 'off',
23
+ },
24
+ },
25
+ ],
26
+ rules: {
27
+ 'arrow-body-style': [
28
+ 'warn',
29
+ 'always',
30
+ ],
31
+ 'react/prop-types': 'off',
32
+ 'react/function-component-definition': [
33
+ 2,
34
+ {
35
+ namedComponents: 'arrow-function',
36
+ },
37
+ ],
38
+ 'no-spaced-func': 'off',
39
+ 'react-hooks/exhaustive-deps': 'off',
40
+ 'lines-between-class-members': 'off',
41
+ 'no-case-declarations': 'off',
42
+ 'react/require-default-props': 'off',
43
+ 'react/react-in-jsx-scope': 'off',
44
+ 'arrow-parens': [
45
+ 'warn',
46
+ 'always',
47
+ ],
48
+ 'comma-dangle': [
49
+ 'error',
50
+ {
51
+ arrays: 'always-multiline',
52
+ objects: 'always-multiline',
53
+ imports: 'always-multiline',
54
+ exports: 'always-multiline',
55
+ functions: 'always-multiline',
56
+ },
57
+ ],
58
+ 'consistent-return': 'off',
59
+ 'id-length': 'off',
60
+ 'max-len': [
61
+ 'error',
62
+ {
63
+ code: 125,
64
+ ignoreStrings: true,
65
+ ignoreTemplateLiterals: true,
66
+ ignoreUrls: true,
67
+ },
68
+ ],
69
+ 'newline-per-chained-call': [
70
+ 'error',
71
+ {
72
+ ignoreChainWithDepth: 2,
73
+ },
74
+ ],
75
+ 'no-plusplus': [
76
+ 'warn',
77
+ {
78
+ allowForLoopAfterthoughts: true,
79
+ },
80
+ ],
81
+ 'prefer-template': 1,
82
+ radix: 'error',
83
+ 'no-await-in-loop': 'off',
84
+ 'max-params': [
85
+ 'warn',
86
+ {
87
+ max: 3,
88
+ },
89
+ ],
90
+ },
91
+ };
92
+
93
+ module.exports = config;
package/README.md CHANGED
@@ -1,3 +1,44 @@
1
1
  # dceky
2
2
 
3
3
  Cypress toolkit for Harvard DCE
4
+
5
+ ## Installation
6
+
7
+ To use this library in your project, add the following scripts to your `package.json`:
8
+
9
+ ```json
10
+ {
11
+ "scripts": {
12
+ "ky:setup": "npm explore dceky -- npm run ky:setup",
13
+ "ky:start": "npm explore dceky -- npm run ky:start",
14
+ "ky:dev": "npm explore dceky -- npm run ky:dev"
15
+ }
16
+ }
17
+ ```
18
+
19
+ ## Commands
20
+
21
+ ### `ky:setup`
22
+
23
+ **What it does:** Generates the necessary configuration files for your Cypress project:
24
+ - Creates `cypress.config.ts` that automatically merges your global credentials, resources, values, and profiles
25
+ - Generates `cypress/commands/index.ts` that auto-imports all custom commands from your `cypress/commands` directory
26
+
27
+ **When to use:**
28
+ - When you first set up the project
29
+ - After adding new custom commands to `cypress/commands`
30
+ - After modifying global configuration files in `cypress/globals` or profile files in `cypress/profiles`
31
+
32
+ ### `ky:start`
33
+
34
+ **What it does:** Interactive wizard for running Cypress tests.
35
+
36
+ **When to use:**
37
+ - If you want to run cypress tests without regenerating setup files.
38
+
39
+ ### `ky:dev`
40
+
41
+ **What it does:** Runs both `setup` and `start`.
42
+
43
+ **When to use:**
44
+ - If you want to generate setup files and run cypress tests.
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Test to display the profile
3
+ * @author Gardenia Liu
4
+ */
5
+
6
+ describe('Current Profile', () => {
7
+ it('Show current profile', () => {
8
+ cy.log(`Current profile: ${Cypress.env('PROFILE')}`);
9
+ });
10
+ });
@@ -0,0 +1,5 @@
1
+ {
2
+ "name": "Using fixtures to represent data",
3
+ "email": "hello@cypress.io",
4
+ "body": "Fixtures are a great way to mock data for responses to routes"
5
+ }
@@ -0,0 +1,37 @@
1
+ /// <reference types="cypress" />
2
+ // ***********************************************
3
+ // This example commands.ts shows you how to
4
+ // create various custom commands and overwrite
5
+ // existing commands.
6
+ //
7
+ // For more comprehensive examples of custom
8
+ // commands please read more here:
9
+ // https://on.cypress.io/custom-commands
10
+ // ***********************************************
11
+ //
12
+ //
13
+ // -- This is a parent command --
14
+ // Cypress.Commands.add('login', (email, password) => { ... })
15
+ //
16
+ //
17
+ // -- This is a child command --
18
+ // Cypress.Commands.add('drag', { prevSubject: 'element'}, (subject, options) => { ... })
19
+ //
20
+ //
21
+ // -- This is a dual command --
22
+ // Cypress.Commands.add('dismiss', { prevSubject: 'optional'}, (subject, options) => { ... })
23
+ //
24
+ //
25
+ // -- This will overwrite an existing command --
26
+ // Cypress.Commands.overwrite('visit', (originalFn, url, options) => { ... })
27
+ //
28
+ // declare global {
29
+ // namespace Cypress {
30
+ // interface Chainable {
31
+ // login(email: string, password: string): Chainable<void>
32
+ // drag(subject: string, options?: Partial<TypeOptions>): Chainable<Element>
33
+ // dismiss(subject: string, options?: Partial<TypeOptions>): Chainable<Element>
34
+ // visit(originalFn: CommandOriginalFn, url: string, options: Partial<VisitOptions>): Chainable<Element>
35
+ // }
36
+ // }
37
+ // }
@@ -0,0 +1,17 @@
1
+ // ***********************************************************
2
+ // This example support/e2e.ts is processed and
3
+ // loaded automatically before your test files.
4
+ //
5
+ // This is a great place to put global configuration and
6
+ // behavior that modifies Cypress.
7
+ //
8
+ // You can change the location of this file or turn off
9
+ // automatically serving support files with the
10
+ // 'supportFile' configuration option.
11
+ //
12
+ // You can read more here:
13
+ // https://on.cypress.io/configuration
14
+ // ***********************************************************
15
+
16
+ // Import commands.js using ES2015 syntax:
17
+ import './commands'
@@ -0,0 +1,9 @@
1
+ import { defineConfig } from "cypress";
2
+
3
+ export default defineConfig({
4
+ e2e: {
5
+ setupNodeEvents(on, config) {
6
+ // implement node event listeners here
7
+ },
8
+ },
9
+ });
@@ -0,0 +1,23 @@
1
+ # Globals and Profiles Configuration
2
+
3
+ ### Configuration Setup
4
+
5
+ The configuration setup involves the following steps:
6
+
7
+ 1. Split each globals/profiles map into two: `basic` values and `dependsOn` values.
8
+ 2. Merge all `basic` values into a running env object (in order so last ones processed are the highest priority).
9
+ 3. Go through each `dependsOn` value, look up the value it depends on in the running env object.
10
+ 4. Add `dependsOn` values into the running env object (in order so last ones processed are the highest priority).
11
+ 5. Wrap the env object into a config.
12
+
13
+ ### Assumptions
14
+
15
+ * `dependsOn` values must depend on a basic `value`, not on another `dependsOn` value.
16
+
17
+ ### DependsOn Value
18
+
19
+ The `dependsOn` value is an object that has the following structure:
20
+
21
+ * `dependsOn`: the key of the `basic` value that we are depending on
22
+ * `value`: the value that we are depending on (can be a string, number, boolean, etc.)
23
+ * `default`: the default value if the `dependsOn` value is not found
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Ensure gitignore includes the necessary entries for Cypress results
3
+ * @author Yuen Ler Chow
4
+ */
5
+ declare const addToGitIgnore: () => void;
6
+ export default addToGitIgnore;
@@ -0,0 +1,46 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ /* eslint-disable no-console */
7
+ var fs_1 = require("fs");
8
+ var path_1 = __importDefault(require("path"));
9
+ /**
10
+ * Ensure gitignore includes the necessary entries for Cypress results
11
+ * @author Yuen Ler Chow
12
+ */
13
+ var addToGitIgnore = function () {
14
+ var root = path_1.default.join(__dirname, '../..');
15
+ var gitignorePath = path_1.default.join(root, '.gitignore');
16
+ var entries = [
17
+ 'cypress-results/',
18
+ 'cypress/downloads',
19
+ 'cypress/screenshots',
20
+ 'cypress/videos',
21
+ ];
22
+ var gitignoreContent = '';
23
+ if ((0, fs_1.existsSync)(gitignorePath)) {
24
+ gitignoreContent = (0, fs_1.readFileSync)(gitignorePath, 'utf8');
25
+ }
26
+ // Check which entries are missing
27
+ var missingEntries = entries.filter(function (entry) {
28
+ // Check if entry exists (with or without newline)
29
+ var regex = new RegExp("^".concat(entry.replace(/\//g, '\\/'), "$"), 'm');
30
+ return !regex.test(gitignoreContent);
31
+ });
32
+ // Add missing entries
33
+ if (missingEntries.length > 0) {
34
+ if (gitignoreContent && !gitignoreContent.endsWith('\n')) {
35
+ gitignoreContent += '\n';
36
+ }
37
+ gitignoreContent += '\n# Cypress parallel test results (added by dceky)\n';
38
+ missingEntries.forEach(function (entry) {
39
+ gitignoreContent += "".concat(entry, "\n");
40
+ });
41
+ (0, fs_1.writeFileSync)(gitignorePath, gitignoreContent, 'utf8');
42
+ console.log("Added ".concat(missingEntries.length, " entries to .gitignore"));
43
+ }
44
+ };
45
+ exports.default = addToGitIgnore;
46
+ //# sourceMappingURL=addToGitIgnore.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"addToGitIgnore.js","sourceRoot":"","sources":["../../setup/addToGitIgnore.ts"],"names":[],"mappings":";;;;;AAAA,+BAA+B;AAC/B,yBAA6D;AAC7D,8CAAwB;AAExB;;;GAGG;AACH,IAAM,cAAc,GAAG;IACrB,IAAM,IAAI,GAAG,cAAI,CAAC,IAAI,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;IAE3C,IAAM,aAAa,GAAG,cAAI,CAAC,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC,CAAC;IAEpD,IAAM,OAAO,GAAG;QACd,kBAAkB;QAClB,mBAAmB;QACnB,qBAAqB;QACrB,gBAAgB;KACjB,CAAC;IAEF,IAAI,gBAAgB,GAAG,EAAE,CAAC;IAC1B,IAAI,IAAA,eAAU,EAAC,aAAa,CAAC,EAAE,CAAC;QAC9B,gBAAgB,GAAG,IAAA,iBAAY,EAAC,aAAa,EAAE,MAAM,CAAC,CAAC;IACzD,CAAC;IAED,kCAAkC;IAClC,IAAM,cAAc,GAAG,OAAO,CAAC,MAAM,CAAC,UAAC,KAAK;QAC1C,kDAAkD;QAClD,IAAM,KAAK,GAAG,IAAI,MAAM,CAAC,WAAI,KAAK,CAAC,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC,MAAG,EAAE,GAAG,CAAC,CAAC;QAClE,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;IACvC,CAAC,CAAC,CAAC;IAEH,sBAAsB;IACtB,IAAI,cAAc,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QAC9B,IAAI,gBAAgB,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC;YACzD,gBAAgB,IAAI,IAAI,CAAC;QAC3B,CAAC;QACD,gBAAgB,IAAI,sDAAsD,CAAC;QAC3E,cAAc,CAAC,OAAO,CAAC,UAAC,KAAK;YAC3B,gBAAgB,IAAI,UAAG,KAAK,OAAI,CAAC;QACnC,CAAC,CAAC,CAAC;QACH,IAAA,kBAAa,EAAC,aAAa,EAAE,gBAAgB,EAAE,MAAM,CAAC,CAAC;QACvD,OAAO,CAAC,GAAG,CAAC,gBAAS,cAAc,CAAC,MAAM,2BAAwB,CAAC,CAAC;IACtE,CAAC;AACH,CAAC,CAAC;AAEF,kBAAe,cAAc,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Ensure required configuration files exist in the consumer repo
3
+ * @author Yuen Ler Chow
4
+ */
5
+ declare const checkRequiredFiles: () => void;
6
+ export default checkRequiredFiles;
@@ -0,0 +1,58 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ /* eslint-disable no-console */
7
+ var fs_1 = require("fs");
8
+ var path_1 = __importDefault(require("path"));
9
+ /**
10
+ * Ensure required configuration files exist in the consumer repo
11
+ * @author Yuen Ler Chow
12
+ */
13
+ var checkRequiredFiles = function () {
14
+ var root = path_1.default.join(__dirname, '../..');
15
+ var globalsPath = path_1.default.join(root, 'cypress/globals');
16
+ var profilesPath = path_1.default.join(root, 'cypress/profiles');
17
+ // Common file extensions to check
18
+ var extensions = ['.js', '.ts', '.json', '.mjs', '.cjs'];
19
+ // Required global files
20
+ var requiredGlobals = [
21
+ 'GlobalCredentials',
22
+ 'GlobalResources',
23
+ 'GlobalValues',
24
+ ];
25
+ // Determine profile file name (default is stage)
26
+ var profileName = process.env.CYPRESS_PROFILE || 'stage';
27
+ var requiredProfile = "".concat(profileName, ".Profile");
28
+ // Check for missing files
29
+ var missingFiles = [];
30
+ // Check global files
31
+ requiredGlobals.forEach(function (file) {
32
+ var filePath = path_1.default.join(globalsPath, file);
33
+ var found = extensions.some(function (ext) {
34
+ return (0, fs_1.existsSync)("".concat(filePath).concat(ext));
35
+ });
36
+ if (!found) {
37
+ missingFiles.push("cypress/globals/".concat(file, ".ts"));
38
+ }
39
+ });
40
+ // Check profile file
41
+ var profileFilePath = path_1.default.join(profilesPath, requiredProfile);
42
+ var profileFound = extensions.some(function (ext) {
43
+ return (0, fs_1.existsSync)("".concat(profileFilePath).concat(ext));
44
+ });
45
+ if (!profileFound) {
46
+ missingFiles.push("cypress/profiles/".concat(requiredProfile, ".ts"));
47
+ }
48
+ if (missingFiles.length > 0) {
49
+ console.error('\nMissing required configuration files in this project:');
50
+ missingFiles.forEach(function (file) {
51
+ console.error(" - ".concat(file));
52
+ });
53
+ console.error('\nPlease create these files before running setup.');
54
+ process.exit(1);
55
+ }
56
+ };
57
+ exports.default = checkRequiredFiles;
58
+ //# sourceMappingURL=checkRequiredFiles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"checkRequiredFiles.js","sourceRoot":"","sources":["../../setup/checkRequiredFiles.ts"],"names":[],"mappings":";;;;;AAAA,+BAA+B;AAC/B,yBAAgC;AAChC,8CAAwB;AAExB;;;GAGG;AACH,IAAM,kBAAkB,GAAG;IACzB,IAAM,IAAI,GAAG,cAAI,CAAC,IAAI,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;IAE3C,IAAM,WAAW,GAAG,cAAI,CAAC,IAAI,CAAC,IAAI,EAAE,iBAAiB,CAAC,CAAC;IACvD,IAAM,YAAY,GAAG,cAAI,CAAC,IAAI,CAAC,IAAI,EAAE,kBAAkB,CAAC,CAAC;IAEzD,kCAAkC;IAClC,IAAM,UAAU,GAAG,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,CAAC,CAAC;IAE3D,wBAAwB;IACxB,IAAM,eAAe,GAAG;QACtB,mBAAmB;QACnB,iBAAiB;QACjB,cAAc;KACf,CAAC;IAEF,iDAAiD;IACjD,IAAM,WAAW,GAAG,OAAO,CAAC,GAAG,CAAC,eAAe,IAAI,OAAO,CAAC;IAC3D,IAAM,eAAe,GAAG,UAAG,WAAW,aAAU,CAAC;IAEjD,0BAA0B;IAC1B,IAAM,YAAY,GAAa,EAAE,CAAC;IAElC,qBAAqB;IACrB,eAAe,CAAC,OAAO,CAAC,UAAC,IAAI;QAC3B,IAAM,QAAQ,GAAG,cAAI,CAAC,IAAI,CAAC,WAAW,EAAE,IAAI,CAAC,CAAC;QAC9C,IAAM,KAAK,GAAG,UAAU,CAAC,IAAI,CAAC,UAAC,GAAG;YAChC,OAAO,IAAA,eAAU,EAAC,UAAG,QAAQ,SAAG,GAAG,CAAE,CAAC,CAAC;QACzC,CAAC,CAAC,CAAC;QACH,IAAI,CAAC,KAAK,EAAE,CAAC;YACX,YAAY,CAAC,IAAI,CAAC,0BAAmB,IAAI,QAAK,CAAC,CAAC;QAClD,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,qBAAqB;IACrB,IAAM,eAAe,GAAG,cAAI,CAAC,IAAI,CAAC,YAAY,EAAE,eAAe,CAAC,CAAC;IACjE,IAAM,YAAY,GAAG,UAAU,CAAC,IAAI,CAAC,UAAC,GAAG;QACvC,OAAO,IAAA,eAAU,EAAC,UAAG,eAAe,SAAG,GAAG,CAAE,CAAC,CAAC;IAChD,CAAC,CAAC,CAAC;IACH,IAAI,CAAC,YAAY,EAAE,CAAC;QAClB,YAAY,CAAC,IAAI,CAAC,2BAAoB,eAAe,QAAK,CAAC,CAAC;IAC9D,CAAC;IAED,IAAI,YAAY,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QAC5B,OAAO,CAAC,KAAK,CAAC,yDAAyD,CAAC,CAAC;QACzE,YAAY,CAAC,OAAO,CAAC,UAAC,IAAI;YACxB,OAAO,CAAC,KAAK,CAAC,cAAO,IAAI,CAAE,CAAC,CAAC;QAC/B,CAAC,CAAC,CAAC;QACH,OAAO,CAAC,KAAK,CAAC,mDAAmD,CAAC,CAAC;QACnE,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;AACH,CAAC,CAAC;AAEF,kBAAe,kBAAkB,CAAC"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Generate an index.ts file that imports and runs all command files in cypress/commands
3
+ * This should be called from cypress.config.js
4
+ * @author Yuen Ler Chow
5
+ */
6
+ declare const genCommandImportFile: () => string;
7
+ export default genCommandImportFile;
@@ -0,0 +1,66 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ var fs_1 = __importDefault(require("fs"));
7
+ var path_1 = __importDefault(require("path"));
8
+ /**
9
+ * Generate an index.ts file that imports and runs all command files in cypress/commands
10
+ * This should be called from cypress.config.js
11
+ * @author Yuen Ler Chow
12
+ */
13
+ var genCommandImportFile = function () {
14
+ var root = path_1.default.join(__dirname, '../..');
15
+ var cypressCommandsDir = path_1.default.join(root, 'cypress/commands');
16
+ var outputFile = path_1.default.join(cypressCommandsDir, 'index.ts');
17
+ var topOfFileComment = '// Auto-generated by dceky - do not edit manually';
18
+ // Check if the directory exists
19
+ if (!fs_1.default.existsSync(cypressCommandsDir)) {
20
+ // Create the directory
21
+ fs_1.default.mkdirSync(cypressCommandsDir, { recursive: true });
22
+ // Create an empty file so init doesn't fail
23
+ fs_1.default.writeFileSync(outputFile, "".concat(topOfFileComment, "\n"));
24
+ return outputFile;
25
+ }
26
+ // Get all files in the directory
27
+ var files = fs_1.default.readdirSync(cypressCommandsDir);
28
+ var commandFiles = [];
29
+ // Filter out non-JS/TS files and process each file
30
+ files.forEach(function (file) {
31
+ // Skip non-JS/TS files (like .d.ts, .map, etc.)
32
+ if (!file.endsWith('.js') && !file.endsWith('.ts')) {
33
+ return;
34
+ }
35
+ // Skip index files
36
+ if (file === 'index.js' || file === 'index.ts') {
37
+ return;
38
+ }
39
+ // Determine the file's path
40
+ var filePath = path_1.default.join(cypressCommandsDir, file);
41
+ // Check if it's a file (not a directory)
42
+ var stats = fs_1.default.statSync(filePath);
43
+ if (!stats.isFile()) {
44
+ return;
45
+ }
46
+ // Store the file name
47
+ commandFiles.push(file);
48
+ });
49
+ // Generate require statements and function calls
50
+ var requires = [];
51
+ var calls = [];
52
+ commandFiles.forEach(function (file) {
53
+ var requirePath = "./".concat(file);
54
+ // Create a safe variable name (replace non-alphanumeric with underscore)
55
+ var importName = file.replace(/\.(js|ts)$/, '');
56
+ var varName = importName.replace(/[^a-zA-Z0-9]/g, '_');
57
+ requires.push("const ".concat(varName, " = require('").concat(requirePath, "');"));
58
+ calls.push("".concat(varName, ".default();"));
59
+ });
60
+ // Build the final content
61
+ var content = "".concat(topOfFileComment, "\n").concat(requires.join('\n'), "\n\n").concat(calls.join('\n'));
62
+ // Write to the output file
63
+ fs_1.default.writeFileSync(outputFile, content, 'utf8');
64
+ };
65
+ exports.default = genCommandImportFile;
66
+ //# sourceMappingURL=genCommandImportFile.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"genCommandImportFile.js","sourceRoot":"","sources":["../../setup/genCommandImportFile.ts"],"names":[],"mappings":";;;;;AAAA,0CAAoB;AACpB,8CAAwB;AAExB;;;;GAIG;AACH,IAAM,oBAAoB,GAAG;IAC3B,IAAM,IAAI,GAAG,cAAI,CAAC,IAAI,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;IAE3C,IAAM,kBAAkB,GAAG,cAAI,CAAC,IAAI,CAAC,IAAI,EAAE,kBAAkB,CAAC,CAAC;IAC/D,IAAM,UAAU,GAAG,cAAI,CAAC,IAAI,CAAC,kBAAkB,EAAE,UAAU,CAAC,CAAC;IAC7D,IAAM,gBAAgB,GAAG,mDAAmD,CAAC;IAE7E,gCAAgC;IAChC,IAAI,CAAC,YAAE,CAAC,UAAU,CAAC,kBAAkB,CAAC,EAAE,CAAC;QACvC,uBAAuB;QACvB,YAAE,CAAC,SAAS,CAAC,kBAAkB,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;QACtD,4CAA4C;QAC5C,YAAE,CAAC,aAAa,CAAC,UAAU,EAAE,UAAG,gBAAgB,OAAI,CAAC,CAAC;QACtD,OAAO,UAAU,CAAC;IACpB,CAAC;IAED,iCAAiC;IACjC,IAAM,KAAK,GAAG,YAAE,CAAC,WAAW,CAAC,kBAAkB,CAAC,CAAC;IACjD,IAAM,YAAY,GAAa,EAAE,CAAC;IAElC,mDAAmD;IACnD,KAAK,CAAC,OAAO,CAAC,UAAC,IAAI;QACjB,gDAAgD;QAChD,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAC;YACnD,OAAO;QACT,CAAC;QAED,mBAAmB;QACnB,IAAI,IAAI,KAAK,UAAU,IAAI,IAAI,KAAK,UAAU,EAAE,CAAC;YAC/C,OAAO;QACT,CAAC;QAED,4BAA4B;QAC5B,IAAM,QAAQ,GAAG,cAAI,CAAC,IAAI,CAAC,kBAAkB,EAAE,IAAI,CAAC,CAAC;QAErD,yCAAyC;QACzC,IAAM,KAAK,GAAG,YAAE,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;QACpC,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,EAAE,CAAC;YACpB,OAAO;QACT,CAAC;QAED,sBAAsB;QACtB,YAAY,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC1B,CAAC,CAAC,CAAC;IAEH,iDAAiD;IACjD,IAAM,QAAQ,GAAa,EAAE,CAAC;IAC9B,IAAM,KAAK,GAAa,EAAE,CAAC;IAE3B,YAAY,CAAC,OAAO,CAAC,UAAC,IAAI;QACxB,IAAM,WAAW,GAAG,YAAK,IAAI,CAAE,CAAC;QAChC,yEAAyE;QACzE,IAAM,UAAU,GAAG,IAAI,CAAC,OAAO,CAAC,YAAY,EAAE,EAAE,CAAC,CAAC;QAClD,IAAM,OAAO,GAAG,UAAU,CAAC,OAAO,CAAC,eAAe,EAAE,GAAG,CAAC,CAAC;QAEzD,QAAQ,CAAC,IAAI,CAAC,gBAAS,OAAO,yBAAe,WAAW,QAAK,CAAC,CAAC;QAC/D,KAAK,CAAC,IAAI,CAAC,UAAG,OAAO,gBAAa,CAAC,CAAC;IACtC,CAAC,CAAC,CAAC;IAEH,0BAA0B;IAC1B,IAAM,OAAO,GAAG,UAAG,gBAAgB,eAAK,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,iBAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAE,CAAC;IAErF,2BAA2B;IAC3B,YAAE,CAAC,aAAa,CAAC,UAAU,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;AAChD,CAAC,CAAC;AAEF,kBAAe,oBAAoB,CAAC"}
@@ -0,0 +1,13 @@
1
+ import type GlobalsOrProfile from '../types/GlobalsOrProfile';
2
+ import type DependentValue from '../types/DependentValue';
3
+ /**
4
+ * Resolve all dependent values using already-merged basics.
5
+ * @author Gardenia Liu
6
+ * @param dependentMaps with dependencies on basics
7
+ * @param basics entries
8
+ * @returns env with all dependent values resolved
9
+ */
10
+ declare const resolveDependents: (dependentMaps: {
11
+ [k: string]: DependentValue;
12
+ }[], basics: GlobalsOrProfile) => GlobalsOrProfile;
13
+ export default resolveDependents;
@@ -0,0 +1,50 @@
1
+ "use strict";
2
+ var __rest = (this && this.__rest) || function (s, e) {
3
+ var t = {};
4
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
5
+ t[p] = s[p];
6
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
7
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
8
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
9
+ t[p[i]] = s[p[i]];
10
+ }
11
+ return t;
12
+ };
13
+ Object.defineProperty(exports, "__esModule", { value: true });
14
+ /**
15
+ * Resolve all dependent values using already-merged basics.
16
+ * @author Gardenia Liu
17
+ * @param dependentMaps with dependencies on basics
18
+ * @param basics entries
19
+ * @returns env with all dependent values resolved
20
+ */
21
+ var resolveDependents = function (dependentMaps, basics) {
22
+ var resolved = {};
23
+ // Loop through all of the dependency maps
24
+ dependentMaps.forEach(function (depMap) {
25
+ // Loop through all entries within dependency map
26
+ Object.entries(depMap).forEach(function (_a) {
27
+ var k = _a[0], depVal = _a[1];
28
+ // Get basic selector the value depends on
29
+ var selector = basics[depVal.dependsOn];
30
+ // Create table of values selector can be
31
+ var _b = depVal, dependsOn = _b.dependsOn, table = __rest(_b, ["dependsOn"]);
32
+ // Get the selector's picked value
33
+ var picked = table[selector];
34
+ if (picked !== undefined) {
35
+ resolved[k] = picked;
36
+ }
37
+ else if ('default' in table) {
38
+ resolved[k] = table.default;
39
+ }
40
+ else {
41
+ // eslint-disable-next-line max-len
42
+ console.warn("[cypress.config] Could not resolve ".concat(k, ", dependsOn=").concat(dependsOn, ", selector=").concat(String(selector)));
43
+ process.exit(1);
44
+ }
45
+ });
46
+ });
47
+ return resolved;
48
+ };
49
+ exports.default = resolveDependents;
50
+ //# sourceMappingURL=resolveDependents.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"resolveDependents.js","sourceRoot":"","sources":["../../../../setup/genConfiguration/helpers/resolveDependents.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAKA;;;;;;GAMG;AACH,IAAM,iBAAiB,GAAG,UACxB,aAAgD,EAChD,MAAwB;IAExB,IAAM,QAAQ,GAAqB,EAAE,CAAC;IAEtC,0CAA0C;IAC1C,aAAa,CAAC,OAAO,CAAC,UAAC,MAAM;QAC3B,iDAAiD;QACjD,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,UAAC,EAAW;gBAAV,CAAC,QAAA,EAAE,MAAM,QAAA;YACxC,0CAA0C;YAC1C,IAAM,QAAQ,GAAG,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;YAE1C,yCAAyC;YACzC,IAAM,KAA0B,MAAkC,EAA1D,SAAS,eAAA,EAAK,KAAK,cAArB,aAAuB,CAAqC,CAAC;YAEnE,kCAAkC;YAClC,IAAM,MAAM,GAAG,KAAK,CAAC,QAAQ,CAAC,CAAC;YAE/B,IAAI,MAAM,KAAK,SAAS,EAAE,CAAC;gBACzB,QAAQ,CAAC,CAAC,CAAC,GAAG,MAAM,CAAC;YACvB,CAAC;iBAAM,IAAI,SAAS,IAAI,KAAK,EAAE,CAAC;gBAC9B,QAAQ,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC;YAC9B,CAAC;iBAAM,CAAC;gBACN,mCAAmC;gBACnC,OAAO,CAAC,IAAI,CAAC,6CAAsC,CAAC,yBAAe,SAAS,wBAAc,MAAM,CAAC,QAAQ,CAAC,CAAE,CAAC,CAAC;gBAC9G,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;YAClB,CAAC;QACH,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,OAAO,QAAQ,CAAC;AAClB,CAAC,CAAC;AAEF,kBAAe,iBAAiB,CAAC"}
@@ -0,0 +1,10 @@
1
+ import type GlobalsOrProfile from '../types/GlobalsOrProfile';
2
+ import type SplitEnv from '../types/SplitEnv';
3
+ /**
4
+ * Split one map into basic and dependent values
5
+ * @author Gardenia Liu
6
+ * @param map to split
7
+ * @returns split basic and dependent values map
8
+ */
9
+ declare const splitEnv: (map: GlobalsOrProfile) => SplitEnv;
10
+ export default splitEnv;
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ /**
4
+ * Split one map into basic and dependent values
5
+ * @author Gardenia Liu
6
+ * @param map to split
7
+ * @returns split basic and dependent values map
8
+ */
9
+ var splitEnv = function (map) {
10
+ var basic = {};
11
+ var dependent = {};
12
+ Object.entries(map).forEach(function (_a) {
13
+ var k = _a[0], v = _a[1];
14
+ // If entry has dependsOn relationship, add it to dependent dictionary
15
+ if (typeof v === 'object' && 'dependsOn' in v) {
16
+ dependent[k] = v;
17
+ // Otherwise, add it to basic dictionary
18
+ }
19
+ else {
20
+ basic[k] = v;
21
+ }
22
+ });
23
+ // Returns separated basic and dependent values
24
+ return { basic: basic, dependent: dependent };
25
+ };
26
+ exports.default = splitEnv;
27
+ //# sourceMappingURL=splitEnv.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"splitEnv.js","sourceRoot":"","sources":["../../../../setup/genConfiguration/helpers/splitEnv.ts"],"names":[],"mappings":";;AAKA;;;;;GAKG;AACH,IAAM,QAAQ,GAAG,UAAC,GAAqB;IACrC,IAAM,KAAK,GAAqB,EAAE,CAAC;IACnC,IAAM,SAAS,GAAoC,EAAE,CAAC;IAEtD,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,UAAC,EAAM;YAAL,CAAC,QAAA,EAAE,CAAC,QAAA;QAChC,sEAAsE;QACtE,IAAI,OAAO,CAAC,KAAK,QAAQ,IAAI,WAAW,IAAI,CAAC,EAAE,CAAC;YAC9C,SAAS,CAAC,CAAC,CAAC,GAAG,CAAmB,CAAC;YACrC,wCAAwC;QACxC,CAAC;aAAM,CAAC;YACN,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;QACf,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,+CAA+C;IAC/C,OAAO,EAAE,KAAK,OAAA,EAAE,SAAS,WAAA,EAAE,CAAC;AAC9B,CAAC,CAAC;AAEF,kBAAe,QAAQ,CAAC"}
@@ -0,0 +1,15 @@
1
+ import type GlobalsOrProfile from './types/GlobalsOrProfile';
2
+ /**
3
+ * Generate Cypress configuration based on global credentials,
4
+ * variables, resources, and profiles
5
+ * @author Gardenia Liu
6
+ * @author Gabe Abrams
7
+ */
8
+ declare const genConfiguration: () => {
9
+ e2e: {
10
+ experimentalOriginDependencies: boolean;
11
+ baseUrl: string;
12
+ env: GlobalsOrProfile;
13
+ };
14
+ };
15
+ export default genConfiguration;