@blaxel/core 0.2.14-dev.91 → 0.2.14-dev.92

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.
@@ -17,14 +17,23 @@ const internal_1 = require("./internal");
17
17
  (0, vitest_1.expect)(hash).toBe('5d41402abc4b2a76b9719d911017c592');
18
18
  });
19
19
  });
20
+ const testCases = [
21
+ {
22
+ workspace: 'charlou-dev',
23
+ type: 'function',
24
+ name: 'blaxel-search',
25
+ expected: '594d9322779f4a07a55a7bf1050360c6'
26
+ }, {
27
+ workspace: 'charlou-dev',
28
+ type: 'agent',
29
+ name: 'toto',
30
+ expected: '1bb3a151bda194751b062df8edb59eaf',
31
+ }
32
+ ];
20
33
  (0, vitest_1.describe)('getGlobalUniqueHash', () => {
21
- (0, vitest_1.it)('returns a hash for the combined workspace, type, and name', () => {
22
- // The input string will be 'ws-type-name'
23
- const expected = (0, internal_1.getAlphanumericLimitedHash)('ws-type-name', 48);
24
- (0, vitest_1.expect)((0, internal_1.getGlobalUniqueHash)('ws', 'type', 'name')).toBe(expected);
25
- });
26
- (0, vitest_1.it)('returns a 48-character hash by default', () => {
27
- const hash = (0, internal_1.getGlobalUniqueHash)('a', 'b', 'c');
28
- (0, vitest_1.expect)(hash.length).toBeLessThanOrEqual(48);
34
+ testCases.forEach(({ workspace, type, name, expected }) => {
35
+ (0, vitest_1.it)(`returns ${expected} for ${workspace}-${type}-${name}`, () => {
36
+ (0, vitest_1.expect)((0, internal_1.getGlobalUniqueHash)(workspace, type, name)).toBe(expected);
37
+ });
29
38
  });
30
39
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blaxel/core",
3
- "version": "0.2.14-dev.91",
3
+ "version": "0.2.14-dev.92",
4
4
  "description": "Blaxel Core SDK for TypeScript",
5
5
  "license": "MIT",
6
6
  "author": "Blaxel, INC (https://blaxel.ai)",