         doc.insert 0, 'hi', =>
           test.strictEqual doc.snapshot, 'hi'
           test.strictEqual doc.getText(), 'hi'
-          @model.getSnapshot @name, ({snapshot}) ->
+          @model.getSnapshot @name, (error, {snapshot}) ->
             test.strictEqual snapshot, 'hi'
             test.done()
     

          throw new Error 'Should not have received op when the doc was unfollowed'
    
        doc.close =>
          @model.applyOp @name, {v:0, op:[{i:'asdf', p:0}]}, (version, error) =>
            test.done()

    'created locally is set on new docs': (test) ->

          # Also need to test that ops sent afterwards get sent correctly.
          # because that behaviour IS CURRENTLY BROKEN

          @model.getSnapshot @name, (error, {snapshot}) ->
            test.strictEqual snapshot, ''
            test.done()

