Add a stable, renderer-neutral web test API for Valdi apps
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 35/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- playwright, typescript
- Ambito
- developer-experience, frontend, testing
Direzione di ricerca
Start by reading the existing debugger input/query protocol and the valdi_test component testing API; the issue does not name source files or tests. Define a renderer-neutral browser test contract with a browser runner adapter and conformance coverage, then verify applications can test the listed interactions without depending on renderer-specific DOM details.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Problem
Valdi applications currently have to test real browser behavior through renderer-specific DOM details. In our downstream app, Puppeteer tests must know whether a control renders as valdi-input, a native input, an element id, data-accessibility-id, or an ARIA attribute. Renderer upgrades can change those details even when the Valdi component tree and user-visible behavior are unchanged, forcing broad rewrites of otherwise valid tests.
valdi_test is useful for component logic, but it cannot replace browser-level coverage for layout, navigation/history, persistence, focus/keyboard input, scrolling, file picking, and other web integrations. Downstream apps need a supported contract for those behaviors that is independent of the web renderer's current DOM shape.
Proposed solution
Provide a first-party web test driver or harness whose public API is expressed in Valdi concepts rather than CSS selectors or generated DOM structure. At minimum it should support:
- locating elements by
accessibilityId(and optionally stable explicit test IDs) - tap/click, text replacement, key input, selection, scroll, and file upload
- normalized reads/assertions for text, value, existence, visibility, enabled state, and bounds
- a deterministic signal for initial render, re-render, and navigation completion
- adapters for a common browser runner such as Playwright or Puppeteer
- a renderer conformance suite so renderer changes update the adapter without breaking application tests
The existing debugger input/query protocol (query, tap, text, key, scroll) looks like a promising foundation if it can be exposed to browser tests as a documented, versioned API. The important part is that applications depend on a stable Valdi testing contract and the renderer owns the translation to DOM/native implementation details.
Alternatives considered
We currently maintain raw Puppeteer selectors with fallback unions such as valdi-input#field, input[name=field], #accessibility-id, [data-accessibility-id=...], and [aria-label=...]. This works temporarily but duplicates renderer knowledge across every downstream app and still requires widespread edits when the renderer changes.
Pure valdi_test component tests cover logic but miss browser integration. A downstream-only wrapper reduces repetition in one repository, but it cannot provide compatibility guarantees or a conformance suite for renderer changes.
Related discussion
No response
Additional context
A representative goal would be for an application test to say, conceptually, driver.findByAccessibilityId('gaugeSt').replaceText('28') and remain valid when Valdi changes the underlying web element or attribute mapping.
- Lingua principale
- C++
- Stelle
- 16.4k
- Fork
- 538
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di Snapchat/Valdi
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 3/5 Mezza giornata Idoneità per principianti 55/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 50/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 55/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di Snapchat/Valdi
Issue simili
-
new issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
llvm/llvm-project#245835 ·
I maintainer di solito rispondono entro 1 giorno
-
documentation
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 72/100
EchoTools/nevr-runtime#2823 ·
I maintainer di solito rispondono entro 1 giorno
-
Fix a typo in H5Centry.cAperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 85/100
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
triton-lang/triton#12945 ·
I maintainer di solito rispondono entro 1 giorno
-
Releases do not move the `latest` Docker tag: the branch `30.12` is taken for the latest release branchForse già presa @alexey-milovidov l’ha presa oggi. Apertacomp-ci-infrastructure unexpected behaviour
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
ClickHouse/ClickHouse#134282 ·
I maintainer di solito rispondono entro 1 giorno