make parameterized testing easier
Nessuno ha ancora preso questa issue.
- Lingua principale
- JavaScript
- Stelle
- 18.3k
- Fork
- 2k
- Merge medio
- 2g 12h
- PR unite (30g)
- 28
Descrizione
I use parameterization in testing because it finds a lot of corner-case bugs.
Test results look like this:
I test many possible new configurations including extremes, etc, and then also test a range of configurations that shouldn't impact the new feature but might because of code proximity.
It does find bugs
In Jasmine and w/ ES5+Promises it's hard to implement manually because of all the weird scoping rules and promises and lack of ES6 tools like let. You can see my implementation here: https://github.com/plotly/plotly.js/blob/fe6f8d05828a789205448376c2d0f32ef71652a2/test/jasmine/tests/pikul_test.js#L28-L143
The messiness comes from scoping rules and reusing logic and etc. But it works well!
There is a module available on GitHub that has a much nicer interface: https://github.com/paucls/jasmine-parameterized
but not sure about maintenance or other solutions.
Thoughts?
edit: also i'm back after a move, will get back around to this stuff mid/late next week- have to prepare a course
Guida per i contributori
Apri 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.
Direzione di ricerca
Inizia con l’implementazione dei test parametrizzati in test/jasmine/tests/pikul_test.js#L28-L143 ed esamina il modulo jasmine-parameterized collegato. Confronta la sua interfaccia e il suo stato di manutenzione con la configurazione Jasmine e ES5+Promises del repository. Poiché l’issue non ha criteri di accettazione concreti, sarebbe necessario stabilire prima un approccio proposto e una definizione di completamento.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- javascript
- Ambito
- testing
- Tipo di issue
- Funzionalità
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Stato di attività
- Ferma
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 25/100