 fs = require 'fs'
 
 describe "PathWatcher", ->
+  beforeEach ->
+    fs.writeFileSync('/tmp/watch.txt', '')
+
   afterEach ->
     pathWatcher.closeAllWatchers()
 
   describe ".getWatchedPaths()", ->
     it "returns an array of all watched paths", ->
-      fs.writeFileSync('/tmp/watch.txt', '')
-
       expect(pathWatcher.getWatchedPaths()).toEqual []
       watcher1 = pathWatcher.watch '/tmp/watch.txt', ->
       expect(pathWatcher.getWatchedPaths()).toEqual ['/tmp/watch.txt']


  describe "when a watched path is changed", ->
    it "fires the callback with the event type and empty path", ->
      fs.writeFileSync('/tmp/watch.txt', '')

      eventType = null
      eventPath = null
      watcher = pathWatcher.watch '/tmp/watch.txt', (type, path) ->


  describe "when a watched path is renamed", ->
    it "fires the callback with the event type and new path and watches the new path", ->
      eventType = null
      eventPath = null
      watcher = pathWatcher.watch '/tmp/watch.txt', (type, path) ->
