test: add a test for a overflow bug on Text -> Time cast

This bug was fixed in d09c6b74d768ef661a5a5ecf61d968948c16b43e.