use spies in the test/pin.js