Tweak code style
Improve test cases for util-path.js