@servicetitan/startup 31.5.0 → 31.6.0

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 (143) hide show
  1. package/dist/cli/commands/build.d.ts +1 -1
  2. package/dist/cli/commands/build.d.ts.map +1 -1
  3. package/dist/cli/commands/build.js.map +1 -1
  4. package/dist/cli/commands/bundle-package.d.ts +1 -1
  5. package/dist/cli/commands/bundle-package.d.ts.map +1 -1
  6. package/dist/cli/commands/bundle-package.js.map +1 -1
  7. package/dist/cli/commands/eslint.d.ts +1 -1
  8. package/dist/cli/commands/eslint.d.ts.map +1 -1
  9. package/dist/cli/commands/eslint.js.map +1 -1
  10. package/dist/cli/commands/get-command.js +2 -2
  11. package/dist/cli/commands/get-command.js.map +1 -1
  12. package/dist/cli/commands/index.d.ts +1 -1
  13. package/dist/cli/commands/index.d.ts.map +1 -1
  14. package/dist/cli/commands/index.js +1 -1
  15. package/dist/cli/commands/index.js.map +1 -1
  16. package/dist/cli/commands/init.d.ts +1 -1
  17. package/dist/cli/commands/init.d.ts.map +1 -1
  18. package/dist/cli/commands/init.js.map +1 -1
  19. package/dist/cli/commands/lint.d.ts +1 -1
  20. package/dist/cli/commands/lint.d.ts.map +1 -1
  21. package/dist/cli/commands/lint.js.map +1 -1
  22. package/dist/cli/commands/mfe-publish.d.ts +1 -1
  23. package/dist/cli/commands/mfe-publish.d.ts.map +1 -1
  24. package/dist/cli/commands/mfe-publish.js.map +1 -1
  25. package/dist/cli/commands/prepare-package.d.ts +1 -1
  26. package/dist/cli/commands/prepare-package.d.ts.map +1 -1
  27. package/dist/cli/commands/prepare-package.js.map +1 -1
  28. package/dist/cli/commands/review/rules/index.d.ts.map +1 -1
  29. package/dist/cli/commands/review/rules/index.js +4 -0
  30. package/dist/cli/commands/review/rules/index.js.map +1 -1
  31. package/dist/cli/commands/review/rules/require-all-react-dependencies.d.ts +14 -0
  32. package/dist/cli/commands/review/rules/require-all-react-dependencies.d.ts.map +1 -0
  33. package/dist/cli/commands/review/rules/require-all-react-dependencies.js +64 -0
  34. package/dist/cli/commands/review/rules/require-all-react-dependencies.js.map +1 -0
  35. package/dist/cli/commands/review/rules/require-one-react-version.d.ts +5 -0
  36. package/dist/cli/commands/review/rules/require-one-react-version.d.ts.map +1 -0
  37. package/dist/cli/commands/review/rules/require-one-react-version.js +25 -0
  38. package/dist/cli/commands/review/rules/require-one-react-version.js.map +1 -0
  39. package/dist/cli/commands/review/rules/require-one-uikit-version.d.ts.map +1 -1
  40. package/dist/cli/commands/review/rules/require-one-uikit-version.js +1 -0
  41. package/dist/cli/commands/review/rules/require-one-uikit-version.js.map +1 -1
  42. package/dist/cli/commands/review/utils/format-depends-on.d.ts +1 -0
  43. package/dist/cli/commands/review/utils/format-depends-on.d.ts.map +1 -1
  44. package/dist/cli/commands/review/utils/format-depends-on.js +15 -8
  45. package/dist/cli/commands/review/utils/format-depends-on.js.map +1 -1
  46. package/dist/cli/commands/review/utils/set-version.d.ts +2 -1
  47. package/dist/cli/commands/review/utils/set-version.d.ts.map +1 -1
  48. package/dist/cli/commands/review/utils/set-version.js +4 -2
  49. package/dist/cli/commands/review/utils/set-version.js.map +1 -1
  50. package/dist/cli/commands/start.d.ts +1 -1
  51. package/dist/cli/commands/start.d.ts.map +1 -1
  52. package/dist/cli/commands/start.js.map +1 -1
  53. package/dist/cli/commands/test/index.d.ts +2 -0
  54. package/dist/cli/commands/test/index.d.ts.map +1 -0
  55. package/dist/cli/commands/test/index.js +20 -0
  56. package/dist/cli/commands/test/index.js.map +1 -0
  57. package/dist/cli/commands/test/runners/index.d.ts +3 -0
  58. package/dist/cli/commands/test/runners/index.d.ts.map +1 -0
  59. package/dist/cli/commands/test/runners/index.js +21 -0
  60. package/dist/cli/commands/test/runners/index.js.map +1 -0
  61. package/dist/cli/commands/test/runners/jest.d.ts +7 -0
  62. package/dist/cli/commands/test/runners/jest.d.ts.map +1 -0
  63. package/dist/cli/commands/test/runners/jest.js +43 -0
  64. package/dist/cli/commands/test/runners/jest.js.map +1 -0
  65. package/dist/cli/commands/test/runners/vitest.d.ts +4 -0
  66. package/dist/cli/commands/test/runners/vitest.d.ts.map +1 -0
  67. package/dist/cli/commands/test/runners/vitest.js +86 -0
  68. package/dist/cli/commands/test/runners/vitest.js.map +1 -0
  69. package/dist/cli/commands/test/tests.d.ts +18 -0
  70. package/dist/cli/commands/test/tests.d.ts.map +1 -0
  71. package/dist/cli/commands/{tests.js → test/tests.js} +10 -9
  72. package/dist/cli/commands/test/tests.js.map +1 -0
  73. package/dist/cli/utils/bundle.d.ts.map +1 -1
  74. package/dist/cli/utils/bundle.js +7 -4
  75. package/dist/cli/utils/bundle.js.map +1 -1
  76. package/dist/cli/utils/set-node-options.d.ts.map +1 -1
  77. package/dist/cli/utils/set-node-options.js.map +1 -1
  78. package/dist/index.d.ts +0 -1
  79. package/dist/index.d.ts.map +1 -1
  80. package/dist/index.js +0 -1
  81. package/dist/index.js.map +1 -1
  82. package/dist/utils/get-configuration.d.ts +8 -2
  83. package/dist/utils/get-configuration.d.ts.map +1 -1
  84. package/dist/utils/get-configuration.js +10 -2
  85. package/dist/utils/get-configuration.js.map +1 -1
  86. package/dist/utils/get-jest-config.d.ts +1 -7
  87. package/dist/utils/get-jest-config.d.ts.map +1 -1
  88. package/dist/utils/get-jest-config.js +49 -58
  89. package/dist/utils/get-jest-config.js.map +1 -1
  90. package/dist/webpack/create-webpack-config.js +1 -2
  91. package/dist/webpack/create-webpack-config.js.map +1 -1
  92. package/dist/webpack/utils/testing/get-compiler.js.map +1 -1
  93. package/package.json +16 -14
  94. package/src/cli/commands/build.ts +1 -1
  95. package/src/cli/commands/bundle-package.ts +1 -1
  96. package/src/cli/commands/eslint.ts +1 -1
  97. package/src/cli/commands/get-command.ts +1 -1
  98. package/src/cli/commands/index.ts +1 -1
  99. package/src/cli/commands/init.ts +1 -1
  100. package/src/cli/commands/lint.ts +1 -1
  101. package/src/cli/commands/mfe-publish.ts +1 -1
  102. package/src/cli/commands/prepare-package.ts +1 -1
  103. package/src/cli/commands/review/rules/__tests__/require-all-react-dependencies.test.ts +132 -0
  104. package/src/cli/commands/review/rules/__tests__/require-one-package-version.test.ts +0 -1
  105. package/src/cli/commands/review/rules/__tests__/require-one-react-version.test.ts +22 -0
  106. package/src/cli/commands/review/rules/__tests__/{require-one-uikit-version.ts → require-one-uikit-version.test.ts} +1 -0
  107. package/src/cli/commands/review/rules/index.ts +4 -0
  108. package/src/cli/commands/review/rules/require-all-react-dependencies.ts +53 -0
  109. package/src/cli/commands/review/rules/require-one-react-version.ts +9 -0
  110. package/src/cli/commands/review/rules/require-one-uikit-version.ts +1 -0
  111. package/src/cli/commands/review/utils/__tests__/set-version.test.ts +18 -8
  112. package/src/cli/commands/review/utils/format-depends-on.ts +8 -5
  113. package/src/cli/commands/review/utils/set-version.ts +10 -2
  114. package/src/cli/commands/start.ts +1 -1
  115. package/src/cli/commands/test/__tests__/tests.test.ts +78 -0
  116. package/src/cli/commands/test/index.ts +1 -0
  117. package/src/cli/commands/{__tests__/tests.test.ts → test/runners/__tests__/jest.test.ts} +10 -13
  118. package/src/cli/commands/test/runners/__tests__/vitest.test.ts +150 -0
  119. package/src/cli/commands/test/runners/index.ts +2 -0
  120. package/src/cli/commands/{tests.ts → test/runners/jest.ts} +5 -16
  121. package/src/cli/commands/test/runners/vitest.ts +70 -0
  122. package/src/cli/commands/test/tests.ts +34 -0
  123. package/src/cli/utils/__tests__/bundle.test.ts +1 -1
  124. package/src/cli/utils/bundle.ts +8 -3
  125. package/src/cli/utils/set-node-options.ts +2 -2
  126. package/src/index.ts +0 -1
  127. package/src/utils/__tests__/get-configuration.test.ts +48 -11
  128. package/src/utils/__tests__/get-jest-config.test.ts +35 -61
  129. package/src/utils/get-configuration.ts +14 -3
  130. package/src/utils/get-jest-config.ts +39 -47
  131. package/src/webpack/__tests__/create-webpack-config-shared-dependencies.test.ts +1 -1
  132. package/src/webpack/__tests__/create-webpack-config-web-component.test.ts +1 -1
  133. package/src/webpack/__tests__/create-webpack-config.test.ts +1 -1
  134. package/src/webpack/create-webpack-config.ts +1 -2
  135. package/src/webpack/utils/testing/get-compiler.ts +1 -1
  136. package/dist/cli/commands/tests.d.ts +0 -13
  137. package/dist/cli/commands/tests.d.ts.map +0 -1
  138. package/dist/cli/commands/tests.js.map +0 -1
  139. package/dist/jest/index.d.ts +0 -2
  140. package/dist/jest/index.d.ts.map +0 -1
  141. package/dist/jest/index.js +0 -16
  142. package/dist/jest/index.js.map +0 -1
  143. package/src/jest/index.ts +0 -5
@@ -42,7 +42,7 @@ jest.mock('mini-css-extract-plugin', () =>
42
42
  jest.mock('moment-locales-webpack-plugin', () => jest.fn());
43
43
  jest.mock('terser-webpack-plugin', () => jest.fn());
44
44
  jest.mock('webpack', () => ({
45
- ...jest.requireActual('webpack'),
45
+ DefinePlugin: jest.fn(),
46
46
  IgnorePlugin: jest.fn(),
47
47
  ProvidePlugin: jest.fn(),
48
48
  }));
@@ -80,8 +80,7 @@ function getContext({ configuration = {} }: Overrides, options: Options): Contex
80
80
  );
81
81
 
82
82
  const args = argv as Arguments;
83
- const emitExposedDependencies =
84
- options.emitExposedDependencies ?? !!args['exposed-dependencies'];
83
+ const emitExposedDependencies = options.emitExposedDependencies;
85
84
 
86
85
  return {
87
86
  codeCoverage: options.codeCoverage ?? !!args['code-coverage'],
@@ -36,7 +36,7 @@ export function getCompilerFactory(cwd: string) {
36
36
  },
37
37
  config
38
38
  )
39
- );
39
+ )!;
40
40
 
41
41
  compiler.outputFileSystem = createFsFromVolume(new Volume()) as any;
42
42
 
@@ -1,13 +0,0 @@
1
- import { Config } from '@jest/types';
2
- import { Command } from '.';
3
- /**
4
- * Named as tests to exclude it from the Jest pattern
5
- */
6
- export declare class Tests implements Command {
7
- private args;
8
- readonly greedy = true;
9
- constructor(args: Config.Argv);
10
- description(): string;
11
- execute(): Promise<void>;
12
- }
13
- //# sourceMappingURL=tests.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"tests.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/tests.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAGrC,OAAO,EAAE,OAAO,EAAE,MAAM,GAAG,CAAC;AAE5B;;GAEG;AACH,qBAAa,KAAM,YAAW,OAAO;IAGrB,OAAO,CAAC,IAAI;IAFxB,QAAQ,CAAC,MAAM,QAAQ;gBAEH,IAAI,EAAE,MAAM,CAAC,IAAI;IAErC,WAAW;IAKL,OAAO;CAWhB"}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../src/cli/commands/tests.ts"],"sourcesContent":["import { Config } from '@jest/types';\nimport { runCLI } from '@jest/core';\nimport { getJestConfigCLI, logErrors } from '../../utils';\nimport { Command } from '.';\n\n/**\n * Named as tests to exclude it from the Jest pattern\n */\nexport class Tests implements Command {\n readonly greedy = true;\n\n constructor(private args: Config.Argv) {}\n\n description() {\n return 'run tests';\n }\n\n @logErrors\n async execute() {\n const jestConfig = getJestConfigCLI(this.args);\n const {\n results: { success },\n } = await runCLI(jestConfig, [process.cwd()]);\n\n if (!success) {\n // eslint-disable-next-line require-atomic-updates\n process.exitCode = 1;\n }\n }\n}\n"],"names":["Tests","description","execute","jestConfig","getJestConfigCLI","args","results","success","runCLI","process","cwd","exitCode","greedy"],"mappings":";;;;+BAQaA;;;eAAAA;;;sBAPU;uBACqB;;;;;;;;;;;;;;;;;;;;;;;AAMrC,MAAMA;IAKTC,cAAc;QACV,OAAO;IACX;IAEA,MACMC,UAAU;QACZ,MAAMC,aAAaC,IAAAA,uBAAgB,EAAC,IAAI,CAACC,IAAI;QAC7C,MAAM,EACFC,SAAS,EAAEC,OAAO,EAAE,EACvB,GAAG,MAAMC,IAAAA,YAAM,EAACL,YAAY;YAACM,QAAQC,GAAG;SAAG;QAE5C,IAAI,CAACH,SAAS;YACV,kDAAkD;YAClDE,QAAQE,QAAQ,GAAG;QACvB;IACJ;IAjBA,YAAY,AAAQN,IAAiB,CAAE;;QAFvC,uBAASO,UAAT,KAAA;aAEoBP,OAAAA;aAFXO,SAAS;IAEsB;AAkB5C"}
@@ -1,2 +0,0 @@
1
- export declare function createJestConfig(): import("../utils").JestConfiguration;
2
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/jest/index.ts"],"names":[],"mappings":"AAEA,wBAAgB,gBAAgB,yCAE/B"}
@@ -1,16 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", {
3
- value: true
4
- });
5
- Object.defineProperty(exports, "createJestConfig", {
6
- enumerable: true,
7
- get: function() {
8
- return createJestConfig;
9
- }
10
- });
11
- const _utils = require("../utils");
12
- function createJestConfig() {
13
- return (0, _utils.getJestConfig)();
14
- }
15
-
16
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../src/jest/index.ts"],"sourcesContent":["import { getJestConfig } from '../utils';\n\nexport function createJestConfig() {\n return getJestConfig();\n}\n"],"names":["createJestConfig","getJestConfig"],"mappings":";;;;+BAEgBA;;;eAAAA;;;uBAFc;AAEvB,SAASA;IACZ,OAAOC,IAAAA,oBAAa;AACxB"}
package/src/jest/index.ts DELETED
@@ -1,5 +0,0 @@
1
- import { getJestConfig } from '../utils';
2
-
3
- export function createJestConfig() {
4
- return getJestConfig();
5
- }