Add failing fs.async.list spec.

This commit is contained in:
Corey Johnson & Nathan Sobo
2012-01-03 11:18:08 -07:00
parent e23d3824e8
commit b3a7e1e097

View File

@@ -0,0 +1,15 @@
fs = require 'fs'
describe "fs", ->
describe ".async", ->
describe ".list(directoryPath)", ->
directoryPath = nil
beforeEach -> directoryPath = require.resolve 'fixtures/file-finder-dir'
it "returns a promise that resolves to the contents of that directory", ->
waitsFor (complete) ->
promise = fs.async.list(directoryPath)
promise.done (result) ->
expect(result).toEqual fs.list(directoryPath)
promise.done complete