@teambit/tracker 1.0.1175 → 1.0.1176

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.
@@ -1,5 +1,12 @@
1
1
  "use strict";
2
2
 
3
+ function path() {
4
+ const data = _interopRequireWildcard(require("path"));
5
+ path = function () {
6
+ return data;
7
+ };
8
+ return data;
9
+ }
3
10
  function _chai() {
4
11
  const data = require("chai");
5
12
  _chai = function () {
@@ -14,6 +21,20 @@ function _componentId() {
14
21
  };
15
22
  return data;
16
23
  }
24
+ function _legacy() {
25
+ const data = require("@teambit/legacy.constants");
26
+ _legacy = function () {
27
+ return data;
28
+ };
29
+ return data;
30
+ }
31
+ function _legacy2() {
32
+ const data = require("@teambit/legacy.bit-map");
33
+ _legacy2 = function () {
34
+ return data;
35
+ };
36
+ return data;
37
+ }
17
38
  function _determineMainFile() {
18
39
  const data = _interopRequireDefault(require("./determine-main-file"));
19
40
  _determineMainFile = function () {
@@ -22,12 +43,50 @@ function _determineMainFile() {
22
43
  return data;
23
44
  }
24
45
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
46
+ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
47
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
48
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
49
+ function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
50
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
51
+ function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
52
+ const createAddedComponent = (overrides = {}) => _objectSpread({
53
+ componentId: _componentId().ComponentID.fromObject({
54
+ name: 'bar/foo'
55
+ }, 'my-scope'),
56
+ files: [],
57
+ mainFile: undefined,
58
+ trackDir: 'bar',
59
+ idFromPath: undefined
60
+ }, overrides);
61
+
62
+ /**
63
+ * the thrown error carries the component-id, the expected main-file pattern and the file list,
64
+ * all assembled separately from the exception type - so assert on them rather than on the class
65
+ * alone, otherwise a regression in any of those details still passes.
66
+ */
67
+ const expectToThrowMissingMainFile = (addedComponent, expectedMainFile, expectedFiles) => {
68
+ let error;
69
+ try {
70
+ (0, _determineMainFile().default)(addedComponent, null);
71
+ } catch (err) {
72
+ error = err;
73
+ }
74
+ (0, _chai().expect)(error).to.be.an.instanceOf(_legacy2().MissingMainFile);
75
+ (0, _chai().expect)(error?.componentId).to.equal('my-scope/bar/foo');
76
+ (0, _chai().expect)(error?.mainFile).to.equal(expectedMainFile);
77
+ (0, _chai().expect)(error?.files).to.deep.equal(expectedFiles.map(file => path().normalize(file)));
78
+ (0, _chai().expect)(error?.message).to.have.string('does not contain a main file');
79
+ (0, _chai().expect)(error?.message).to.have.string('my-scope/bar/foo');
80
+ };
81
+
82
+ // the pattern reported when no strategy matched, e.g. "index.[js, ts, ...]"
83
+ const indexMainFilePattern = `${_legacy().DEFAULT_INDEX_NAME}.[${_legacy().DEFAULT_INDEX_EXTS.join(', ')}]`;
25
84
  const toFiles = paths => paths.map(relativePath => ({
26
85
  relativePath,
27
86
  test: false,
28
87
  name: relativePath.split('/').pop()
29
88
  }));
30
- const addedComponent = (trackDir, files, mainFile) => ({
89
+ const addedComponentAt = (trackDir, files, mainFile) => ({
31
90
  componentId: _componentId().ComponentID.fromObject({
32
91
  name: 'comp'
33
92
  }, 'my-scope'),
@@ -38,27 +97,133 @@ const addedComponent = (trackDir, files, mainFile) => ({
38
97
  immediateDir: trackDir.split('/').pop()
39
98
  });
40
99
  describe('determineMainFile', () => {
100
+ describe('user did not specify a main file', () => {
101
+ it('should throw MissingMainFile with the component details when no file matches any strategy', () => {
102
+ const addedComponent = createAddedComponent({
103
+ files: [{
104
+ relativePath: 'bar/foo1.js'
105
+ }, {
106
+ relativePath: 'bar/foo2.js'
107
+ }]
108
+ });
109
+ expectToThrowMissingMainFile(addedComponent, indexMainFilePattern, ['bar/foo1.js', 'bar/foo2.js']);
110
+ });
111
+ it('should use the only file when the component has a single file', () => {
112
+ const addedComponent = createAddedComponent({
113
+ files: [{
114
+ relativePath: 'bar/foo1.js'
115
+ }]
116
+ });
117
+ (0, _chai().expect)((0, _determineMainFile().default)(addedComponent, null)).to.equal('bar/foo1.js');
118
+ });
119
+ it('should identify the closest index file as the main file when multiple index files exist', () => {
120
+ const addedComponent = createAddedComponent({
121
+ files: [{
122
+ relativePath: 'bar/exceptions/some-exception.js'
123
+ }, {
124
+ relativePath: 'bar/exceptions/index.js'
125
+ }, {
126
+ relativePath: 'bar/index.js'
127
+ }, {
128
+ relativePath: 'bar/foo.js'
129
+ }]
130
+ });
131
+ (0, _chai().expect)((0, _determineMainFile().default)(addedComponent, null)).to.equal('bar/index.js');
132
+ });
133
+ it('should resolve a file with the same name as the immediate directory when no index file exists', () => {
134
+ const addedComponent = createAddedComponent({
135
+ files: [{
136
+ relativePath: 'bar/bar.js'
137
+ }, {
138
+ relativePath: 'bar/foo.js'
139
+ }],
140
+ immediateDir: 'bar'
141
+ });
142
+ (0, _chai().expect)((0, _determineMainFile().default)(addedComponent, null)).to.equal('bar/bar.js');
143
+ });
144
+ it('should prefer an index file over a file with the same name as the immediate directory', () => {
145
+ const addedComponent = createAddedComponent({
146
+ files: [{
147
+ relativePath: 'bar/bar.js'
148
+ }, {
149
+ relativePath: 'bar/index.js'
150
+ }],
151
+ immediateDir: 'bar'
152
+ });
153
+ (0, _chai().expect)((0, _determineMainFile().default)(addedComponent, null)).to.equal('bar/index.js');
154
+ });
155
+ it('should resolve the angular entry point file', () => {
156
+ const addedComponent = createAddedComponent({
157
+ files: [{
158
+ relativePath: 'bar/public-api.ts'
159
+ }, {
160
+ relativePath: 'bar/foo.ts'
161
+ }]
162
+ });
163
+ (0, _chai().expect)((0, _determineMainFile().default)(addedComponent, null)).to.equal('bar/public-api.ts');
164
+ });
165
+ it('should keep the main file of the existing component-map', () => {
166
+ const addedComponent = createAddedComponent({
167
+ files: [{
168
+ relativePath: 'bar/foo1.js'
169
+ }, {
170
+ relativePath: 'bar/foo2.js'
171
+ }]
172
+ });
173
+ // only mainFile and rootDir are read by the strategy, so a partial map is enough here
174
+ const existingComponentMap = {
175
+ mainFile: 'foo2.js',
176
+ rootDir: 'bar'
177
+ };
178
+ (0, _chai().expect)((0, _determineMainFile().default)(addedComponent, existingComponentMap)).to.equal('foo2.js');
179
+ });
180
+ });
181
+ describe('user specified a main file', () => {
182
+ it('should use the specified main file when it exists in the files', () => {
183
+ const addedComponent = createAddedComponent({
184
+ files: [{
185
+ relativePath: 'bar/foo1.js'
186
+ }, {
187
+ relativePath: 'bar/foo2.js'
188
+ }],
189
+ mainFile: 'bar/foo2.js'
190
+ });
191
+ (0, _chai().expect)((0, _determineMainFile().default)(addedComponent, null)).to.equal('bar/foo2.js');
192
+ });
193
+ it('should throw MissingMainFile with the component details when the specified main file is not in the files', () => {
194
+ const addedComponent = createAddedComponent({
195
+ files: [{
196
+ relativePath: 'bar/foo1.js'
197
+ }, {
198
+ relativePath: 'bar/foo2.js'
199
+ }],
200
+ mainFile: 'non-exist.js'
201
+ });
202
+ // the user's value is reported as-is here, not the index pattern
203
+ expectToThrowMissingMainFile(addedComponent, 'non-exist.js', ['bar/foo1.js', 'bar/foo2.js']);
204
+ });
205
+ });
41
206
  describe('the workspace root', () => {
42
207
  // an index file at the root and a deeper one: neither is the entry point of a workspace
43
208
  const rootFiles = ['.bitmap', 'README.md', 'index.ts', 'scripts/index.js', 'workspace.jsonc'];
44
209
  it('should default to workspace.jsonc, over the index files', () => {
45
- (0, _chai().expect)((0, _determineMainFile().default)(addedComponent('.', rootFiles), null)).to.equal('workspace.jsonc');
210
+ (0, _chai().expect)((0, _determineMainFile().default)(addedComponentAt('.', rootFiles), null)).to.equal('workspace.jsonc');
46
211
  });
47
212
  it('should take the main file the user gave over the default', () => {
48
- (0, _chai().expect)((0, _determineMainFile().default)(addedComponent('.', rootFiles, 'README.md'), null)).to.equal('README.md');
213
+ (0, _chai().expect)((0, _determineMainFile().default)(addedComponentAt('.', rootFiles, 'README.md'), null)).to.equal('README.md');
49
214
  });
50
215
  it('should keep the main file of the existing entry when re-tracked without one', () => {
51
216
  const existing = {
52
217
  rootDir: '.',
53
218
  mainFile: 'README.md'
54
219
  };
55
- (0, _chai().expect)((0, _determineMainFile().default)(addedComponent('.', rootFiles), existing)).to.equal('README.md');
220
+ (0, _chai().expect)((0, _determineMainFile().default)(addedComponentAt('.', rootFiles), existing)).to.equal('README.md');
56
221
  });
57
222
  });
58
223
  describe('a regular directory', () => {
59
224
  it('should resolve the index file, a workspace.jsonc inside it is a file like any other', () => {
60
225
  const files = ['packages/comp1/index.ts', 'packages/comp1/workspace.jsonc'];
61
- (0, _chai().expect)((0, _determineMainFile().default)(addedComponent('packages/comp1', files), null)).to.equal('packages/comp1/index.ts');
226
+ (0, _chai().expect)((0, _determineMainFile().default)(addedComponentAt('packages/comp1', files), null)).to.equal('packages/comp1/index.ts');
62
227
  });
63
228
  });
64
229
  });
@@ -1 +1 @@
1
- {"version":3,"names":["_chai","data","require","_componentId","_determineMainFile","_interopRequireDefault","e","__esModule","default","toFiles","paths","map","relativePath","test","name","split","pop","addedComponent","trackDir","files","mainFile","componentId","ComponentID","fromObject","idFromPath","immediateDir","describe","rootFiles","it","expect","determineMainFile","to","equal","existing","rootDir"],"sources":["determine-main-file.spec.ts"],"sourcesContent":["import { expect } from 'chai';\nimport { ComponentID } from '@teambit/component-id';\nimport type { ComponentMap, ComponentMapFile } from '@teambit/legacy.bit-map';\nimport determineMainFile from './determine-main-file';\nimport type { AddedComponent } from './add-components';\n\nconst toFiles = (paths: string[]): ComponentMapFile[] =>\n paths.map((relativePath) => ({ relativePath, test: false, name: relativePath.split('/').pop() as string }));\n\nconst addedComponent = (trackDir: string, files: string[], mainFile?: string): AddedComponent => ({\n componentId: ComponentID.fromObject({ name: 'comp' }, 'my-scope'),\n files: toFiles(files),\n mainFile,\n trackDir,\n idFromPath: null,\n immediateDir: trackDir.split('/').pop(),\n});\n\ndescribe('determineMainFile', () => {\n describe('the workspace root', () => {\n // an index file at the root and a deeper one: neither is the entry point of a workspace\n const rootFiles = ['.bitmap', 'README.md', 'index.ts', 'scripts/index.js', 'workspace.jsonc'];\n it('should default to workspace.jsonc, over the index files', () => {\n expect(determineMainFile(addedComponent('.', rootFiles), null)).to.equal('workspace.jsonc');\n });\n it('should take the main file the user gave over the default', () => {\n expect(determineMainFile(addedComponent('.', rootFiles, 'README.md'), null)).to.equal('README.md');\n });\n it('should keep the main file of the existing entry when re-tracked without one', () => {\n const existing = { rootDir: '.', mainFile: 'README.md' } as ComponentMap;\n expect(determineMainFile(addedComponent('.', rootFiles), existing)).to.equal('README.md');\n });\n });\n describe('a regular directory', () => {\n it('should resolve the index file, a workspace.jsonc inside it is a file like any other', () => {\n const files = ['packages/comp1/index.ts', 'packages/comp1/workspace.jsonc'];\n expect(determineMainFile(addedComponent('packages/comp1', files), null)).to.equal('packages/comp1/index.ts');\n });\n });\n});\n"],"mappings":";;AAAA,SAAAA,MAAA;EAAA,MAAAC,IAAA,GAAAC,OAAA;EAAAF,KAAA,YAAAA,CAAA;IAAA,OAAAC,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AACA,SAAAE,aAAA;EAAA,MAAAF,IAAA,GAAAC,OAAA;EAAAC,YAAA,YAAAA,CAAA;IAAA,OAAAF,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AAEA,SAAAG,mBAAA;EAAA,MAAAH,IAAA,GAAAI,sBAAA,CAAAH,OAAA;EAAAE,kBAAA,YAAAA,CAAA;IAAA,OAAAH,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AAAsD,SAAAI,uBAAAC,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAGtD,MAAMG,OAAO,GAAIC,KAAe,IAC9BA,KAAK,CAACC,GAAG,CAAEC,YAAY,KAAM;EAAEA,YAAY;EAAEC,IAAI,EAAE,KAAK;EAAEC,IAAI,EAAEF,YAAY,CAACG,KAAK,CAAC,GAAG,CAAC,CAACC,GAAG,CAAC;AAAY,CAAC,CAAC,CAAC;AAE7G,MAAMC,cAAc,GAAGA,CAACC,QAAgB,EAAEC,KAAe,EAAEC,QAAiB,MAAsB;EAChGC,WAAW,EAAEC,0BAAW,CAACC,UAAU,CAAC;IAAET,IAAI,EAAE;EAAO,CAAC,EAAE,UAAU,CAAC;EACjEK,KAAK,EAAEV,OAAO,CAACU,KAAK,CAAC;EACrBC,QAAQ;EACRF,QAAQ;EACRM,UAAU,EAAE,IAAI;EAChBC,YAAY,EAAEP,QAAQ,CAACH,KAAK,CAAC,GAAG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,EAAE,CAACC,KAAK,CAAC,yBAAyB,CAAC;IAC9G,CAAC,CAAC;EACJ,CAAC,CAAC;AACJ,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["path","data","_interopRequireWildcard","require","_chai","_componentId","_legacy","_legacy2","_determineMainFile","_interopRequireDefault","e","__esModule","default","t","WeakMap","r","n","o","i","f","__proto__","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","ownKeys","keys","getOwnPropertySymbols","filter","enumerable","push","apply","_objectSpread","arguments","length","forEach","_defineProperty","getOwnPropertyDescriptors","defineProperties","_toPropertyKey","value","configurable","writable","_toPrimitive","Symbol","toPrimitive","TypeError","String","Number","createAddedComponent","overrides","componentId","ComponentID","fromObject","name","files","mainFile","undefined","trackDir","idFromPath","expectToThrowMissingMainFile","addedComponent","expectedMainFile","expectedFiles","error","determineMainFile","err","expect","to","be","an","instanceOf","MissingMainFile","equal","deep","map","file","normalize","message","have","string","indexMainFilePattern","DEFAULT_INDEX_NAME","DEFAULT_INDEX_EXTS","join","toFiles","paths","relativePath","test","split","pop","addedComponentAt","immediateDir","describe","it","existingComponentMap","rootDir","rootFiles","existing"],"sources":["determine-main-file.spec.ts"],"sourcesContent":["import * as path from 'path';\nimport { expect } from 'chai';\nimport { ComponentID } from '@teambit/component-id';\nimport { DEFAULT_INDEX_EXTS, DEFAULT_INDEX_NAME } from '@teambit/legacy.constants';\nimport type { ComponentMap, ComponentMapFile } from '@teambit/legacy.bit-map';\nimport { MissingMainFile } from '@teambit/legacy.bit-map';\nimport determineMainFile from './determine-main-file';\nimport type { AddedComponent } from './add-components';\n\nconst createAddedComponent = (overrides: Partial<AddedComponent> = {}): AddedComponent => ({\n componentId: ComponentID.fromObject({ name: 'bar/foo' }, 'my-scope'),\n files: [],\n mainFile: undefined,\n trackDir: 'bar',\n idFromPath: undefined,\n ...overrides,\n});\n\n/**\n * the thrown error carries the component-id, the expected main-file pattern and the file list,\n * all assembled separately from the exception type - so assert on them rather than on the class\n * alone, otherwise a regression in any of those details still passes.\n */\nconst expectToThrowMissingMainFile = (\n addedComponent: AddedComponent,\n expectedMainFile: string,\n expectedFiles: string[]\n) => {\n let error: MissingMainFile | undefined;\n try {\n determineMainFile(addedComponent, null);\n } catch (err: any) {\n error = err;\n }\n expect(error).to.be.an.instanceOf(MissingMainFile);\n expect(error?.componentId).to.equal('my-scope/bar/foo');\n expect(error?.mainFile).to.equal(expectedMainFile);\n expect(error?.files).to.deep.equal(expectedFiles.map((file) => path.normalize(file)));\n expect(error?.message).to.have.string('does not contain a main file');\n expect(error?.message).to.have.string('my-scope/bar/foo');\n};\n\n// the pattern reported when no strategy matched, e.g. \"index.[js, ts, ...]\"\nconst indexMainFilePattern = `${DEFAULT_INDEX_NAME}.[${DEFAULT_INDEX_EXTS.join(', ')}]`;\n\nconst toFiles = (paths: string[]): ComponentMapFile[] =>\n paths.map((relativePath) => ({ relativePath, test: false, name: relativePath.split('/').pop() as string }));\n\nconst addedComponentAt = (trackDir: string, files: string[], mainFile?: string): AddedComponent => ({\n componentId: ComponentID.fromObject({ name: 'comp' }, 'my-scope'),\n files: toFiles(files),\n mainFile,\n trackDir,\n idFromPath: null,\n immediateDir: trackDir.split('/').pop(),\n});\n\ndescribe('determineMainFile', () => {\n describe('user did not specify a main file', () => {\n it('should throw MissingMainFile with the component details when no file matches any strategy', () => {\n const addedComponent = createAddedComponent({\n files: [{ relativePath: 'bar/foo1.js' }, { relativePath: 'bar/foo2.js' }],\n });\n expectToThrowMissingMainFile(addedComponent, indexMainFilePattern, ['bar/foo1.js', 'bar/foo2.js']);\n });\n it('should use the only file when the component has a single file', () => {\n const addedComponent = createAddedComponent({\n files: [{ relativePath: 'bar/foo1.js' }],\n });\n expect(determineMainFile(addedComponent, null)).to.equal('bar/foo1.js');\n });\n it('should identify the closest index file as the main file when multiple index files exist', () => {\n const addedComponent = createAddedComponent({\n files: [\n { relativePath: 'bar/exceptions/some-exception.js' },\n { relativePath: 'bar/exceptions/index.js' },\n { relativePath: 'bar/index.js' },\n { relativePath: 'bar/foo.js' },\n ],\n });\n expect(determineMainFile(addedComponent, null)).to.equal('bar/index.js');\n });\n it('should resolve a file with the same name as the immediate directory when no index file exists', () => {\n const addedComponent = createAddedComponent({\n files: [{ relativePath: 'bar/bar.js' }, { relativePath: 'bar/foo.js' }],\n immediateDir: 'bar',\n });\n expect(determineMainFile(addedComponent, null)).to.equal('bar/bar.js');\n });\n it('should prefer an index file over a file with the same name as the immediate directory', () => {\n const addedComponent = createAddedComponent({\n files: [{ relativePath: 'bar/bar.js' }, { relativePath: 'bar/index.js' }],\n immediateDir: 'bar',\n });\n expect(determineMainFile(addedComponent, null)).to.equal('bar/index.js');\n });\n it('should resolve the angular entry point file', () => {\n const addedComponent = createAddedComponent({\n files: [{ relativePath: 'bar/public-api.ts' }, { relativePath: 'bar/foo.ts' }],\n });\n expect(determineMainFile(addedComponent, null)).to.equal('bar/public-api.ts');\n });\n it('should keep the main file of the existing component-map', () => {\n const addedComponent = createAddedComponent({\n files: [{ relativePath: 'bar/foo1.js' }, { relativePath: 'bar/foo2.js' }],\n });\n // only mainFile and rootDir are read by the strategy, so a partial map is enough here\n const existingComponentMap = { mainFile: 'foo2.js', rootDir: 'bar' } as ComponentMap;\n expect(determineMainFile(addedComponent, existingComponentMap)).to.equal('foo2.js');\n });\n });\n describe('user specified a main file', () => {\n it('should use the specified main file when it exists in the files', () => {\n const addedComponent = createAddedComponent({\n files: [{ relativePath: 'bar/foo1.js' }, { relativePath: 'bar/foo2.js' }],\n mainFile: 'bar/foo2.js',\n });\n expect(determineMainFile(addedComponent, null)).to.equal('bar/foo2.js');\n });\n it('should throw MissingMainFile with the component details when the specified main file is not in the files', () => {\n const addedComponent = createAddedComponent({\n files: [{ relativePath: 'bar/foo1.js' }, { relativePath: 'bar/foo2.js' }],\n mainFile: 'non-exist.js',\n });\n // the user's value is reported as-is here, not the index pattern\n expectToThrowMissingMainFile(addedComponent, 'non-exist.js', ['bar/foo1.js', 'bar/foo2.js']);\n });\n });\n describe('the workspace root', () => {\n // an index file at the root and a deeper one: neither is the entry point of a workspace\n const rootFiles = ['.bitmap', 'README.md', 'index.ts', 'scripts/index.js', 'workspace.jsonc'];\n it('should default to workspace.jsonc, over the index files', () => {\n expect(determineMainFile(addedComponentAt('.', rootFiles), null)).to.equal('workspace.jsonc');\n });\n it('should take the main file the user gave over the default', () => {\n expect(determineMainFile(addedComponentAt('.', rootFiles, 'README.md'), null)).to.equal('README.md');\n });\n it('should keep the main file of the existing entry when re-tracked without one', () => {\n const existing = { rootDir: '.', mainFile: 'README.md' } as ComponentMap;\n expect(determineMainFile(addedComponentAt('.', rootFiles), existing)).to.equal('README.md');\n });\n });\n describe('a regular directory', () => {\n it('should resolve the index file, a workspace.jsonc inside it is a file like any other', () => {\n const files = ['packages/comp1/index.ts', 'packages/comp1/workspace.jsonc'];\n expect(determineMainFile(addedComponentAt('packages/comp1', files), null)).to.equal('packages/comp1/index.ts');\n });\n });\n});\n"],"mappings":";;AAAA,SAAAA,KAAA;EAAA,MAAAC,IAAA,GAAAC,uBAAA,CAAAC,OAAA;EAAAH,IAAA,YAAAA,CAAA;IAAA,OAAAC,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AACA,SAAAG,MAAA;EAAA,MAAAH,IAAA,GAAAE,OAAA;EAAAC,KAAA,YAAAA,CAAA;IAAA,OAAAH,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AACA,SAAAI,aAAA;EAAA,MAAAJ,IAAA,GAAAE,OAAA;EAAAE,YAAA,YAAAA,CAAA;IAAA,OAAAJ,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AACA,SAAAK,QAAA;EAAA,MAAAL,IAAA,GAAAE,OAAA;EAAAG,OAAA,YAAAA,CAAA;IAAA,OAAAL,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AAEA,SAAAM,SAAA;EAAA,MAAAN,IAAA,GAAAE,OAAA;EAAAI,QAAA,YAAAA,CAAA;IAA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CAAC7B,EAAE,CAACK,KAAK,CAAC,iBAAiB,CAAC;IAC/F,CAAC,CAAC;IACFqB,EAAE,CAAC,0DAA0D,EAAE,MAAM;MACnE,IAAA3B,cAAM,EAAC,IAAAF,4BAAiB,EAAC0B,gBAAgB,CAAC,GAAG,EAAEM,SAAS,EAAE,WAAW,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC7B,EAAE,CAACK,KAAK,CAAC,WAAW,CAAC;IACtG,CAAC,CAAC;IACFqB,EAAE,CAAC,6EAA6E,EAAE,MAAM;MACtF,MAAMI,QAAQ,GAAG;QAAEF,OAAO,EAAE,GAAG;QAAExC,QAAQ,EAAE;MAAY,CAAiB;MACxE,IAAAW,cAAM,EAAC,IAAAF,4BAAiB,EAAC0B,gBAAgB,CAAC,GAAG,EAAEM,SAAS,CAAC,EAAEC,QAAQ,CAAC,CAAC,CAAC9B,EAAE,CAACK,KAAK,CAAC,WAAW,CAAC;IAC7F,CAAC,CAAC;EACJ,CAAC,CAAC;EACFoB,QAAQ,CAAC,qBAAqB,EAAE,MAAM;IACpCC,EAAE,CAAC,qFAAqF,EAAE,MAAM;MAC9F,MAAMvC,KAAK,GAAG,CAAC,yBAAyB,EAAE,gCAAgC,CAAC;MAC3E,IAAAY,cAAM,EAAC,IAAAF,4BAAiB,EAAC0B,gBAAgB,CAAC,gBAAgB,EAAEpC,KAAK,CAAC,EAAE,IAAI,CAAC,CAAC,CAACa,EAAE,CAACK,KAAK,CAAC,yBAAyB,CAAC;IAChH,CAAC,CAAC;EACJ,CAAC,CAAC;AACJ,CAAC,CAAC","ignoreList":[]}
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@teambit/tracker",
3
- "version": "1.0.1175",
3
+ "version": "1.0.1176",
4
4
  "homepage": "https://bit.cloud/teambit/component/tracker",
5
5
  "main": "dist/index.js",
6
6
  "componentId": {
7
7
  "scope": "teambit.component",
8
8
  "name": "tracker",
9
- "version": "1.0.1175"
9
+ "version": "1.0.1176"
10
10
  },
11
11
  "dependencies": {
12
12
  "chalk": "4.1.2",
@@ -18,30 +18,30 @@
18
18
  "lodash": "4.17.21",
19
19
  "string-format": "0.5.0",
20
20
  "@teambit/bit-error": "0.0.404",
21
- "@teambit/legacy.utils": "0.0.51",
22
21
  "@teambit/component-id": "1.2.4",
23
22
  "@teambit/legacy-bit-id": "1.1.3",
24
- "@teambit/harmony": "0.4.12",
25
- "@teambit/toolbox.promise.map-pool": "0.0.21",
26
- "@teambit/cli": "0.0.1394",
27
23
  "@teambit/legacy.analytics": "0.0.109",
28
- "@teambit/legacy.bit-map": "0.0.222",
29
24
  "@teambit/legacy.constants": "0.0.45",
30
- "@teambit/legacy.consumer": "0.0.165",
31
25
  "@teambit/legacy.logger": "0.0.62",
32
- "@teambit/workspace.modules.node-modules-linker": "0.0.397",
33
- "@teambit/workspace": "1.0.1175",
34
- "@teambit/envs": "1.0.1175",
26
+ "@teambit/harmony": "0.4.12",
35
27
  "@teambit/harmony.modules.concurrency": "0.0.46",
36
- "@teambit/logger": "0.0.1487"
28
+ "@teambit/toolbox.promise.map-pool": "0.0.21",
29
+ "@teambit/cli": "0.0.1395",
30
+ "@teambit/legacy.utils": "0.0.52",
31
+ "@teambit/legacy.bit-map": "0.0.223",
32
+ "@teambit/legacy.consumer": "0.0.166",
33
+ "@teambit/workspace.modules.node-modules-linker": "0.0.398",
34
+ "@teambit/workspace": "1.0.1176",
35
+ "@teambit/envs": "1.0.1176",
36
+ "@teambit/logger": "0.0.1488"
37
37
  },
38
38
  "devDependencies": {
39
39
  "@types/fs-extra": "9.0.7",
40
40
  "@types/lodash": "4.14.165",
41
41
  "@types/mocha": "9.1.0",
42
42
  "@teambit/harmony.envs.core-aspect-env": "2.1.1",
43
- "@teambit/harmony.testing.load-aspect": "0.0.433",
44
- "@teambit/workspace.testing.mock-workspace": "0.0.247"
43
+ "@teambit/harmony.testing.load-aspect": "0.0.434",
44
+ "@teambit/workspace.testing.mock-workspace": "0.0.248"
45
45
  },
46
46
  "peerDependencies": {
47
47
  "chai": "5.2.1"