ParamUnittest

Software screenshot:
ParamUnittest
Dettagli del software:
Versione: 0.2
Data di caricamento: 20 Feb 15
Sviluppatore: Enrico Franchi
Licenza: Libero
Popolarità: 56

Rating: 2.3/5 (Total Votes: 3)

ParamUnittest è uno strumento Python progettato per consentire la creazione di test di unità parametrizzate in grado di lavorare con il pacchetto ufficiale unittest Python.
Esempi:
import unittest
import paramunittest
@ Paramunittest.parametrized (
& Nbsp; ('1', '2'),
& Nbsp; # (4, 3),
& Nbsp; ('2', '3'),
& Nbsp; (('4',), {'b': '5'}),
& Nbsp; ((), {'a': 5, 'b': 6}),
& Nbsp; {'a': 5, 'b': 6},
)
Classe TestFoo (paramunittest.ParametrizedTestCase):
& Nbsp; setParameters def (auto, a, b):
& Nbsp; self.a = a
& Nbsp; self.b = b
& Nbsp; def testless (self):
& Nbsp; self.assertLess (self.a, self.b)
@ Paramunittest.parametrized (
& Nbsp; ('1', '2'),
& Nbsp; # (4, 3),
& Nbsp; ('2', '3'),
& Nbsp; (('4',), {'b': '5'}),
& Nbsp; ((), {'a': 5, 'b': 6}),
& Nbsp; {'a': 5, 'b': 6},
)
Classe TestBar (unittest.TestCase):
& Nbsp; setParameters def (auto, a, b):
& Nbsp; self.a = a
& Nbsp; self.b = b
& Nbsp; def testless (self):
& Nbsp; self.assertLess (self.a, self.b)

Requisiti :

  • Python

Programmi simili

PyModel
PyModel

11 May 15

bug-repo-syncer
bug-repo-syncer

14 Apr 15

KaliVeda
KaliVeda

20 Feb 15

Commenti a ParamUnittest

I commenti non trovato
Aggiungi commento
Accendere le immagini!