GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — chore: fix test · chuckchen/opencode@1e2da60

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • packages/app/e2e/projects
    • projects-switch.spec.ts
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎packages/app/e2e/projects/projects-switch.spec.ts‎

Copy file name to clipboardExpand all lines: packages/app/e2e/projects/projects-switch.spec.ts
+11-6Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -92,14 +92,19 @@ test("switching back to a project opens the latest workspace session", async ({
9292

9393
await expect(page).toHaveURL(new RegExp(`/${workspaceSlug}/session(?:[/?#]|$)`))
9494

95-
const created = await createSdk(workspaceDir)
96-
.session.create()
97-
.then((x) => x.data?.id)
98-
if (!created) throw new Error(`Failed to create session for workspace: ${workspaceDir}`)
95+
// Create a session by sending a prompt
96+
const prompt = page.locator(promptSelector)
97+
await expect(prompt).toBeVisible()
98+
await prompt.fill("test")
99+
await page.keyboard.press("Enter")
100+
101+
// Wait for the URL to update with the new session ID
102+
await expect.poll(() => sessionIDFromUrl(page.url()) ?? "", { timeout: 15_000 }).not.toBe("")
103+
104+
const created = sessionIDFromUrl(page.url())
105+
if (!created) throw new Error(`Failed to get session ID from url: ${page.url()}`)
99106
sessionID = created
100107

101-
await page.goto(sessionPath(workspaceDir, created))
102-
await expect(page.locator(promptSelector)).toBeVisible()
103108
await expect(page).toHaveURL(new RegExp(`/${workspaceSlug}/session/${created}(?:[/?#]|$)`))
104109

105110
await openSidebar(page)

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.