Thanks for sharing!
I integrated it in the Sanderling repository here:
Some details on the development process
As can be seen in the diff view of the linked commit, it also adds a test case for the scenario from the first post. When testing a function that should work on such small input values, it is convenient to use this unit testing framework.
By running these automated tests, we get fast feedback on our parsing implementation. Using this testing method, we get test results less than 5 seconds after changing the parsing code.
For example, if applied only the testing part of the linked commit, those tests would fail with an output like this:
elm-test-rs 0.6.1
-----------------
Total time spent in the elm compiler: 0.39237058s
Running 27 tests. To reproduce these results later, run:
elm-test-rs --seed 1480975004 --fuzz 100 (TODO: pass files to reporter)
↓ Parse memory reading
↓ Parse security status from UI node text
✗ <hint="Security status"><color=#ffffff00>0.5</color></hint>
Nothing
╷
│ Expect.equal
╵
Just 50
TEST RUN FAILED
Duration: 56 ms
Passed: 26
Failed: 1
Running duration (since Node.js start): 265 ms
Using these tests allows fast testing of any new parsing code.