backports.datetime_fromisoformat icon indicating copy to clipboard operation
backports.datetime_fromisoformat copied to clipboard

Add Hypothesis fuzz testing

Open movermeyer opened this issue 7 years ago • 0 comments

There is a nice invariant we can use Hypothesis to test.

datetime.fromisoformat is the inverse of datetime.isoformat

In other words, for every datetime object, dt, dt == datetime.fromisoformat(dt.isoformat())

Hypothesis can be used to test this invariant, using its "datetimes strategy".

movermeyer avatar Jun 30 '18 01:06 movermeyer