Fixed bug in test
attempts to deal with sinon issues