 				done()
 
 		it "should version the dosc created", ->
-			updates = MockDocUpdaterApi.getProjectStructureUpdates(@uploaded_project_id).docUpdates
+			{docUpdates: updates, version} = MockDocUpdaterApi.getProjectStructureUpdates(@uploaded_project_id)
 			expect(updates.length).to.equal(1)
 			update = updates[0]
 			expect(update.userId).to.equal(@owner._id)

				if res.statusCode < 200 || res.statusCode >= 300
					throw new Error("failed to upload file #{res.statusCode}")

				updates = MockDocUpdaterApi.getProjectStructureUpdates(@tpds_project_id).docUpdates
				expect(updates.length).to.equal(1)
				update = updates[0]
				expect(update.userId).to.equal(@owner._id)

				if res.statusCode < 200 || res.statusCode >= 300
					throw new Error("failed to delete folder #{res.statusCode}")

				{docUpdates:updates, version} = MockDocUpdaterApi.getProjectStructureUpdates(example_project_id)
				expect(updates.length).to.equal(1)
				update = updates[0]
				expect(update.userId).to.equal(@owner._id)
				expect(update.pathname).to.equal("/bar/foo_renamed/new_renamed.tex")
				expect(update.newPathname).to.equal("")

				{fileUpdates:updates, version} = MockDocUpdaterApi.getProjectStructureUpdates(example_project_id)
				expect(updates.length).to.equal(1)
				update = updates[0]
				expect(update.userId).to.equal(@owner._id)
				expect(update.pathname).to.equal("/bar/foo_renamed/1pixel_renamed.png")
				expect(update.newPathname).to.equal("")

				ProjectGetter.getProject example_project_id, (error, newProject) =>
					throw error if error?
					@project_1 = newProject
					# replacing a file should update the project structure
