Created
June 17, 2011 00:05
-
-
Save levicole/1030615 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
it 'can apply the canvas to the DOM', -> | |
(setFixtures sandbox()) | |
@canvas.write('#sandbox') | |
(expect document.getElementById("sandbox")).toContain('canvas') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
it 'can clear the canvas', -> | |
ctx = @canvas.ctx | |
spyOn(ctx, 'clearRect') | |
@canvas.clear() | |
expect(ctx.clearRect).toHaveBeenCalled() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment