       scanner.on('path-found', pathHandler = createPathCollector())
       scanner.on('finished-scanning', finishedHandler = jasmine.createSpy())
 
-      runs ->
-        scanner.scan()
-
-      waitsFor ->
-        finishedHandler.callCount > 0
-
+      runs -> scanner.scan()
+      waitsFor -> finishedHandler.callCount > 0
       runs ->
         expect(paths).not.toContain path.join(rootPath, '.git/HEAD')
 

      scanner.on('path-found', pathHandler = createPathCollector())
      scanner.on('finished-scanning', finishedHandler = jasmine.createSpy())

      runs ->
        scanner.scan()

      waitsFor ->
        finishedHandler.callCount > 0

      runs ->
        expect(paths.length).toBe 1
        expect(paths).toContain path.join(rootPath, 'node_modules', 'pkg', 'sample.js')

      scanner.on('path-found', pathHandler = createPathCollector())
      scanner.on('finished-scanning', finishedHandler = jasmine.createSpy())

      runs -> scanner.scan()
      waitsFor -> finishedHandler.callCount > 0
      runs ->
        expect(paths).not.toContain path.join(rootPath, '.gitignore')
