1
0
Fork 0
mirror of https://github.com/jashkenas/coffeescript.git synced 2022-11-09 12:23:24 -05:00
jashkenas--coffeescript/test/test_exceptions.coffee
2010-04-03 10:39:32 -04:00

19 lines
No EOL
202 B
CoffeeScript

# Basic exception throwing.
block: -> (throw 'up')
throws block, 'up'
# Basic try/catch.
result: try
10
finally
15
ok result is 10
result: try
throw 'up'
catch err
err.length
ok result is 2