Daniel@0: beforeEach(function () { Daniel@0: jasmine.addMatchers({ Daniel@0: toBePlaying: function () { Daniel@0: return { Daniel@0: compare: function (actual, expected) { Daniel@0: var player = actual; Daniel@0: Daniel@0: return { Daniel@0: pass: player.currentlyPlayingSong === expected && player.isPlaying Daniel@0: } Daniel@0: } Daniel@0: }; Daniel@0: } Daniel@0: }); Daniel@0: });