string: Cleanup strchrnul test

Clean up code and improve test coverage.
1 file changed