diff --git a/.changeset/kind-lions-cut.md b/.changeset/kind-lions-cut.md new file mode 100644 index 0000000000..a845151cc8 --- /dev/null +++ b/.changeset/kind-lions-cut.md @@ -0,0 +1,2 @@ +--- +--- diff --git a/tests/workflow-tengo/src/pframes/test/ll.test.ts b/tests/workflow-tengo/src/pframes/test/ll.test.ts index a5f777602a..c5ea86aaec 100644 --- a/tests/workflow-tengo/src/pframes/test/ll.test.ts +++ b/tests/workflow-tengo/src/pframes/test/ll.test.ts @@ -110,7 +110,7 @@ tplTest.concurrent.for([ }, ); -eTplTest( +eTplTest.concurrent( 'should correctly execute low level aggregation routine with xsv parsing', async ({ helper, expect, stHelper }) => { const xsvSettings = { diff --git a/tests/workflow-tengo/src/pframes/test/pframe.export.test.ts b/tests/workflow-tengo/src/pframes/test/pframe.export.test.ts index 56a76e9e4a..05decd7ef5 100644 --- a/tests/workflow-tengo/src/pframes/test/pframe.export.test.ts +++ b/tests/workflow-tengo/src/pframes/test/pframe.export.test.ts @@ -11,9 +11,9 @@ const baseSpec = { annotations: {}, }; -tplTest('should export files for p-frame without skipExportForUI annotation', { timeout: 40000 }, +tplTest.concurrent('should export files for p-frame without skipExportForUI annotation', { timeout: 40000 }, async ({ helper, expect, driverKit }) => { - const spec = baseSpec; + const spec = deepClone(baseSpec); const fileHandle = await importFile(driverKit); const result = await helper.renderTemplate( @@ -43,9 +43,9 @@ tplTest('should export files for p-frame without skipExportForUI annotation', { }, ); -tplTest('should not export files for p-frame with hideDataFromUi annotation', { timeout: 40000 }, +tplTest.concurrent('should not export files for p-frame with hideDataFromUi annotation', { timeout: 40000 }, async ({ helper, expect, driverKit }) => { - const spec = { ...baseSpec, annotations: { 'pl7.app/hideDataFromUi': 'true' } }; + const spec = { ...deepClone(baseSpec), annotations: { 'pl7.app/hideDataFromUi': 'true' } }; const fileHandle = await importFile(driverKit); const result = await helper.renderTemplate( @@ -87,3 +87,7 @@ async function importFile(driverKit: DriverKit) { return ourFile.handle; } + +function deepClone(obj: T): T { + return JSON.parse(JSON.stringify(obj)); +} diff --git a/tests/workflow-tengo/src/pframes/test/xsv.export.test.ts b/tests/workflow-tengo/src/pframes/test/xsv.export.test.ts index 3bdc9e7de9..cf1fa9b351 100644 --- a/tests/workflow-tengo/src/pframes/test/xsv.export.test.ts +++ b/tests/workflow-tengo/src/pframes/test/xsv.export.test.ts @@ -71,7 +71,7 @@ const baseSpec = { partitionKeyLength: 2, }; -tplTest.for([ +tplTest.concurrent.for([ { partitionKeyLength: 0, storageFormat: 'Binary' }, { partitionKeyLength: 1, storageFormat: 'Binary' }, { partitionKeyLength: 2, storageFormat: 'Binary' }, @@ -88,7 +88,7 @@ tplTest.for([ // execution takes 1-2 seconds at most. { timeout: 30000 }, async ({ partitionKeyLength, storageFormat }, { helper, expect, driverKit }) => { - const spec = baseSpec; + const spec = deepClone(baseSpec); spec.partitionKeyLength = partitionKeyLength; spec.storageFormat = storageFormat; @@ -129,7 +129,7 @@ tplTest.for([ }, ); -tplTest.for([ +tplTest.concurrent.for([ { partitionKeyLength: 1, storageFormat: 'Binary' }, { partitionKeyLength: 2, storageFormat: 'Binary' }, { partitionKeyLength: 1, storageFormat: 'Json' }, @@ -144,7 +144,7 @@ tplTest.for([ // execution takes 1-2 seconds at most. { timeout: 30000 }, async ({ partitionKeyLength, storageFormat }, { helper, expect, driverKit }) => { - const spec = baseSpec; + const spec = deepClone(baseSpec); spec.partitionKeyLength = partitionKeyLength; spec.storageFormat = storageFormat; @@ -198,7 +198,7 @@ function superPartitionKeys(keyLen: number): string[] { return r; } -tplTest.for([ +tplTest.concurrent.for([ { superPartitionKeyLength: 0, partitionKeyLength: 0, @@ -257,7 +257,7 @@ tplTest.for([ { helper, expect, driverKit }, ) => { const supKeys = superPartitionKeys(superPartitionKeyLength).sort(); - const spec = baseSpec; + const spec = deepClone(baseSpec); spec.partitionKeyLength = partitionKeyLength; spec.storageFormat = storageFormat; @@ -308,3 +308,7 @@ tplTest.for([ if (superPartitionKeyLength === 0) expect(actual).toEqual(expected); }, ); + +function deepClone(obj: T): T { + return JSON.parse(JSON.stringify(obj)); +} diff --git a/tests/workflow-tengo/src/pframes/test/xsv.import.test.ts b/tests/workflow-tengo/src/pframes/test/xsv.import.test.ts index 96ab4cd329..5717af85c7 100644 --- a/tests/workflow-tengo/src/pframes/test/xsv.import.test.ts +++ b/tests/workflow-tengo/src/pframes/test/xsv.import.test.ts @@ -111,7 +111,7 @@ function partitionKeyJson(str: string): any { return JSON.stringify(JSON.parse(str.replace('.index', '').replace('.values', ''))); } -tplTest.for([ +tplTest.concurrent.for([ { partitionKeyLength: 0, storageFormat: 'Binary' }, { partitionKeyLength: 1, storageFormat: 'Binary' }, { partitionKeyLength: 2, storageFormat: 'Binary' }, @@ -128,7 +128,7 @@ tplTest.for([ // execution takes 1-2 seconds at most. { timeout: 30000 }, async ({ partitionKeyLength, storageFormat }, { helper, expect, driverKit }) => { - const spec = baseSpec; + const spec = deepClone(baseSpec); spec.partitionKeyLength = partitionKeyLength; spec.storageFormat = storageFormat; const expectedPKeys = [...expectedPartitionKeys(spec)].sort(); @@ -228,7 +228,7 @@ function superPartitionKeys(keyLen: number): string[] { return r; } -tplTest.for([ +tplTest.concurrent.for([ { superPartitionKeyLength: 0, partitionKeyLength: 0, @@ -284,7 +284,7 @@ tplTest.for([ { timeout: 30000 }, async ({ superPartitionKeyLength, partitionKeyLength, storageFormat }, { helper, expect }) => { const supKeys = superPartitionKeys(superPartitionKeyLength).sort(); - const spec = baseSpec; + const spec = deepClone(baseSpec); spec.partitionKeyLength = partitionKeyLength; spec.storageFormat = storageFormat; // inner keys @@ -393,7 +393,7 @@ tplTest.for([ }, ); -tplTest.for([ +tplTest.concurrent.for([ { superPartitionKeyLength: 0, partitionKeyLength: 0, @@ -449,7 +449,7 @@ tplTest.for([ { timeout: 30000 }, async ({ superPartitionKeyLength, partitionKeyLength, storageFormat }, { helper, expect }) => { const supKeys = superPartitionKeys(superPartitionKeyLength).sort(); - const spec = baseSpec; + const spec = deepClone(baseSpec); spec.partitionKeyLength = partitionKeyLength; spec.storageFormat = storageFormat; // inner keys @@ -548,3 +548,7 @@ tplTest.for([ } }, ); + +function deepClone(obj: T): T { + return JSON.parse(JSON.stringify(obj)); +}