Skip to content

Instantly share code, notes, and snippets.

@yhsiang
Last active August 29, 2015 14:05
Show Gist options
  • Save yhsiang/a76d8e9d040718d0cb79 to your computer and use it in GitHub Desktop.
Save yhsiang/a76d8e9d040718d0cb79 to your computer and use it in GitHub Desktop.
jest-livescript
{
"scripts": {
"test":"jest"
},
"dependencies": {
"LiveScript": "*",
"jest-cli": "^0.1.18"
},
"jest": {
"scriptPreprocessor": "preprocessor.js",
"testFileExtensions": ["ls", "js"]
}
}
jest.dontMock '../sum.ls'
describe 'sum', (,) ->
it 'adds 1 + 2 to equal 3', ->
sum = require '../sum.ls'
expect(sum 1,2).toBe 3
sum = (a, b) -> a + b
module.exports = sum
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment