mozilla/makedrive — pull request #87 by humphd (2014-07-15 20:00:33+00:00)
Title: First client integration tests

This is a working integration test. I've changed a number of things, including:
* make MakeDrive client useable in node.js (with memory provider, and by swapping WebSocket/ws via browserify).
* add a way to turn off auto-sync'ing in the MakeDrive client, such that we can control when it happens in tests.

The test itself uses our authentication utils, gets a token, then sets up a MakeDrive fs instance, wires all the various listeners, writes a file, then tries to sync. If all goes well, it moves through the various states, checking as it goes.

I'd like to write more tests, but it's currently not possible, since running this test after our other WebSocket tests, or writing more than one test like this (you can copy/paste it to see what I mean) will fail with `[Error: Current sync in progress! Try again later!]`. This is hard to make sense of, since I'm using a different username (i.e., generated with a uuid), so nothing should be locked. We need to solve that before I can move forward.