The bundled @effect/ui testing example clicks a missing “Save now” button

Aperta
#11,053 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@effect-bot ci sta già lavorando.

Dal 29/11/2026.

  • #613 di @effect-bot — aperta

Valutazione

Difficoltà
1/5
Tempo stimato
Meno di un'ora
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Ferma
Stack tecnologico
typescript
Ambito
testing

Direzione di ricerca

Read ai-docs/src/10_ui/50_testing.ts around lines 544–553 and compare the example with fixtures/pages/notes/NotePage.ts and fixtures/notes/components/NoteEditor.ts. Run the reproduction command from the issue; changing the click target from “Save now” to “Save” should let the test pass, including the saved notice and hidden editor. An open linked pull request indicates work is already underway.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

What is the type of issue?

Example code is not working

What is the issue?

The bundled App as a Play example fails when it tries to save an edited note. It should show Saved, then hide the editor when the test clicks Hide. Instead it stops at HtmlPlay.click: nothing matches text "Save now".

Reproduced on macOS arm64 with Node 24.22.3, using @effect/[email protected] from UI main at 77391ee50ae3d3175d670facbf675e9a819ba6a6. The @main and SHA-pinned downloads were byte-identical. Run in an empty directory:

cat > package.json <<'JSON'
{
  "private": true,
  "type": "module",
  "imports": {
    "#domain/*": "./fixtures/domain/*.ts",
    "#queries/*": "./fixtures/queries/*.ts"
  }
}
JSON
npm install --min-release-age=0 --ignore-scripts --no-audit --no-fund \
  [email protected] @effect/[email protected] [email protected] [email protected] \
  '@effect/ui@https://pkg.pr.new/Effect-TS/ui/@effect/ui@77391ee50ae3d3175d670facbf675e9a819ba6a6'
guide=node_modules/@effect/ui/ai-docs/src/10_ui
cp -R "$guide/fixtures" .
cp "$guide/50_testing.ts" upstream.test.ts
./node_modules/.bin/vitest run upstream.test.ts --retry 0 -t 'loads a note, saves an edit and shows the notice'

Changing only the click argument to Save passes the assertions for the Saved notice and the hidden editor.

Where did you find it?

ai-docs/src/10_ui/50_testing.ts:544–553 describes and clicks a summary-slot button that the fixture no longer renders. The summary has only the title, and the editor has a Save submit button. fixtures/pages/notes/NotePage.ts:63–73, fixtures/notes/components/NoteEditor.ts:194–197.

Lingua principale
TypeScript
Stelle
16.7k
Fork
808
Merge medio
21h 22m
PR unite (30g)
486

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Effect-TS/effect

Tutte le issue di Effect-TS/effect

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.