Remove a race condition in `watch`.

Currently, `dir_state` can fail in unfortuate ways when a file disappears
between reading a directory listing and calculating a hash of its contents;
this patch fixes the problem by catching the failure and returning NA.
Merge pull request #80 from craigcitro/tests

Make testthat tests more reliable when called from the interpreter.