Closed makermelissa closed 3 years ago
@makermelissa This looks like an elegant solution to the fromisoformat
call in CPython.
Could you add the test for fromisoformat
to our tests for this library?
The CPython source is here, https://github.com/python/cpython/blob/master/Lib/test/datetimetester.py#L1812
Sure thing @brentru
Update: once I started trying out the unit tests, I realized I hadn't implemented this properly with it defaulting to zeroes rather than raising ValueErrors on a bad format. Also, my implementation wasn't complete, so I'm reworking it and doing a proper implementation and that's coming along nicely.
There are more unit tests that are not quite passing, but at least some of them have been enabled/added.
They can be worked on and improved at a later date, but this PR provides the core functionality that I needed and is ready for review.
At this point most of the unit tests that don't pass are due to other functions not being implemented. I updated some of the skip message to reflect this better.
Unfortunately CircuitPython doesn't yet support Counted Repetitions or Non-Capturing groups, so the regex is on the longer side.