Skip to content

Commit 7f980f8

Browse files
committed
chore: removing timeouts as tests are fast enough now
1 parent ba4a8fb commit 7f980f8

File tree

4 files changed

+9
-27
lines changed

4 files changed

+9
-27
lines changed

vscode/extension/tests/bad_setup.spec.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,7 @@ import {
1414
test('missing LSP dependencies shows install prompt', async ({
1515
page,
1616
sharedCodeServer,
17-
}, testInfo) => {
18-
testInfo.setTimeout(120_000) // 2 minutes for venv creation and package installation
17+
}) => {
1918
const tempDir = await fs.mkdtemp(
2019
path.join(os.tmpdir(), 'vscode-test-tcloud-'),
2120
)
@@ -111,8 +110,7 @@ test('lineage, no sqlmesh found', async ({
111110
test.skip('check that the LSP runs correctly by opening lineage when looking at another file before not in workspace', async ({
112111
page,
113112
sharedCodeServer,
114-
}, testInfo) => {
115-
testInfo.setTimeout(120_000) // 2 minutes for venv creation and package installation
113+
}) => {
116114
const tempDir = await fs.mkdtemp(
117115
path.join(os.tmpdir(), 'vscode-test-tcloud-'),
118116
)

vscode/extension/tests/python_env.spec.ts

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -71,12 +71,7 @@ async function setupEnvironment(): Promise<{
7171
}
7272

7373
test.describe('python environment variable injection on sqlmesh_lsp', () => {
74-
test('normal setup - error ', async ({
75-
page,
76-
sharedCodeServer,
77-
}, testInfo) => {
78-
testInfo.setTimeout(120_000)
79-
74+
test('normal setup - error ', async ({ page, sharedCodeServer }) => {
8075
const { tempDir } = await setupEnvironment()
8176
writeEnvironmentConfig(tempDir)
8277
await runTest(page, sharedCodeServer, tempDir)
@@ -120,22 +115,15 @@ async function setupTcloudProject(
120115
}
121116

122117
test.describe('tcloud version', () => {
123-
test('normal setup - error ', async ({
124-
page,
125-
sharedCodeServer,
126-
}, testInfo) => {
127-
testInfo.setTimeout(120_000)
128-
118+
test('normal setup - error ', async ({ page, sharedCodeServer }) => {
129119
const { tempDir, pythonDetails } = await setupEnvironment()
130120
await setupTcloudProject(tempDir, pythonDetails)
131121
writeEnvironmentConfig(tempDir)
132122
await runTest(page, sharedCodeServer, tempDir)
133123
await page.waitForSelector('text=Error creating context')
134124
})
135125

136-
test('normal setup - set', async ({ page, sharedCodeServer }, testInfo) => {
137-
testInfo.setTimeout(120_000)
138-
126+
test('normal setup - set', async ({ page, sharedCodeServer }) => {
139127
const { tempDir, pythonDetails } = await setupEnvironment()
140128
await setupTcloudProject(tempDir, pythonDetails)
141129
writeEnvironmentConfig(tempDir)

vscode/extension/tests/tcloud.spec.ts

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,7 @@ async function setupPythonEnvironment(envDir: string): Promise<string> {
3838
return pythonDetails.pythonPath
3939
}
4040

41-
test('not signed in, shows sign in window', async ({ page }, testInfo) => {
42-
testInfo.setTimeout(120_000) // 2 minutes for venv creation and package installation
41+
test('not signed in, shows sign in window', async ({ page }) => {
4342
const tempDir = await fs.mkdtemp(
4443
path.join(os.tmpdir(), 'vscode-test-tcloud-'),
4544
)
@@ -189,8 +188,7 @@ test('signed in and not installed shows installation window', async ({
189188

190189
test('tcloud sqlmesh_lsp command starts the sqlmesh_lsp in old version when ready', async ({
191190
page,
192-
}, testInfo) => {
193-
testInfo.setTimeout(120_000) // 2 minutes for venv creation and package installation
191+
}) => {
194192
const tempDir = await fs.mkdtemp(
195193
path.join(os.tmpdir(), 'vscode-test-tcloud-'),
196194
)
@@ -351,8 +349,7 @@ test('tcloud sqlmesh_lsp command starts the sqlmesh_lsp in new version when read
351349
// but the test is still useful when running it manually.
352350
test.skip('tcloud not signed in and not installed, shows sign in window and then fact that loaded', async ({
353351
page,
354-
}, testInfo) => {
355-
testInfo.setTimeout(120_000) // 2 minutes for venv creation and package installation
352+
}) => {
356353
const tempDir = await fs.mkdtemp(
357354
path.join(os.tmpdir(), 'vscode-test-tcloud-'),
358355
)

vscode/extension/tests/venv_naming.spec.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,7 @@ import {
1010
SUSHI_SOURCE_PATH,
1111
} from './utils'
1212

13-
test('venv being named .env', async ({ page, sharedCodeServer }, testInfo) => {
14-
testInfo.setTimeout(120_000) // 2 minutes for venv creation and package installation
13+
test('venv being named .env', async ({ page, sharedCodeServer }) => {
1514
const tempDir = await fs.mkdtemp(
1615
path.join(os.tmpdir(), 'vscode-test-tcloud-'),
1716
)

0 commit comments

Comments
 (0)