Fix for test that is broken. Need to spy if the plan is to use verify()

(cherry picked from commit e8bec1bf1075cb7bbfbacba2feeba003f6cdb77e)