It works and is deterministic thanks to line one. I certainly would not use it outside a test, but this allowed me to remove an ugly bit of exposed private API.