Increase test coverage for math.py fabs() function
Aperta
Nessuno ha ancora preso questa issue.
tests
type-feature
- Lingua principale
- Python
- Stelle
- 77.2k
- Fork
- 35.9k
- Metriche di merge delle PR
- Metriche PR in attesa
Descrizione
In Lib/test/test_math.py, the testFabs() method tests integers but not infinity (especially negative infinity).
def testFabs(self):
self.assertRaises(TypeError, math.fabs)
self.ftest('fabs(-1)', math.fabs(-1), 1)
self.ftest('fabs(0)', math.fabs(0), 0)
self.ftest('fabs(1)', math.fabs(1), 1)
I have submitted a PR that increases test coverage for fabs().
Linked PRs
- gh-149060
- gh-149061
- gh-150940
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
Apri Lib/test/test_math.py e esamina testFabs() e l’helper ftest esistente. Confronta le PRs collegate per i casi di Infinity previsti; il lavoro è completato quando i test di fabs() coprono il comportamento mancante segnalato e superano la suite di test math.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- python
- Ambito
- testing-qa
- Tipo di issue
- Funzionalità
- Difficoltà
- 1/5
- Tempo stimato
- Meno di un'ora
- Stato di attività
- Ferma
- Chiarezza
- Specificata chiaramente
- Idoneità per principianti
- 20/100