Skip to content

Commit aa1819e

Browse files
committed
add: docs redirects
1 parent 6a73f8d commit aa1819e

2 files changed

Lines changed: 42 additions & 1 deletion

File tree

apps/web/next.config.mjs

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,20 @@ const nextConfig = {
8282
],
8383
}
8484
},
85+
async redirects() {
86+
return [
87+
{
88+
source: '/docs/sandbox-templates/overview',
89+
destination: '/docs/sandbox-template',
90+
permanent: true,
91+
},
92+
{
93+
source: '/docs/sandbox-templates',
94+
destination: '/docs/sandbox-template',
95+
permanent: true,
96+
},
97+
]
98+
},
8599
}
86100

87101
export default withSearch(

packages/js-sdk/tests/integration/stress.test.ts

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,36 @@ for (let i = 0; i < view.length; i++) {
99
view[i] = Math.floor(Math.random() * 256)
1010
}
1111

12-
const integrationTestTemplate = 'integration-test-v1'
12+
const integrationTestTemplate = 'base'
1313
const sanboxCount = 10
1414

15+
test.skipIf(!isIntegrationTest)(
16+
'stress test sandbox spawns in batches',
17+
async () => {
18+
const TOTAL_COUNT = 500
19+
const BATCH_SIZE = 50
20+
21+
for (let i = 0; i < TOTAL_COUNT; i += BATCH_SIZE) {
22+
const promises: Array<Promise<Sandbox>> = []
23+
for (let j = 0; j < BATCH_SIZE; j++) {
24+
const sbx = Sandbox.create(integrationTestTemplate, {
25+
timeoutMs: 30_000,
26+
})
27+
promises.push(sbx)
28+
}
29+
const res = await Promise.all(promises)
30+
for (const sbx of res) {
31+
console.log(sbx.sandboxId)
32+
}
33+
await wait(1_000)
34+
}
35+
}
36+
)
37+
38+
if (process.env.NODE_ENV === 'development') {
39+
process.exit(0)
40+
}
41+
1542
test.skipIf(!isIntegrationTest)(
1643
'stress test heavy file writes and reads',
1744
async () => {

0 commit comments

Comments
 (0)