tweak index.js test code