 				@tpds_project_id = project_id
 				mkdirp Settings.path.dumpFolder, done
 
-		beforeEach () ->
-			MockDocUpdaterApi.clearProjectStructureUpdates()
+		beforeEach (done) ->
+			MockDocUpdaterApi.clearProjectStructureUpdates()
+			ProjectGetter.getProject @tpds_project_id, (error, project) =>
+				throw error if error?
+				@root_folder_id = project.rootFolder[0]._id.toString()
+				@project_0 = project
+				done()
 
 		it "should version adding a doc", (done) ->
 			tex_file = fs.createReadStream(Path.resolve(__dirname + '/../files/test.tex'))

				expect(update.url).to.be.a('string');
				@original_file_url = update.url

				done()

		it "should version a replacement file", (done) ->
			image_file = fs.createReadStream(Path.resolve(__dirname + '/../files/2pixel.png'))

				expect(update.pathname).to.equal("/1pixel.png")
				expect(update.url).to.be.a('string');

				ProjectGetter.getProject @example_project_id, (error, newProject) =>
					throw error if error?
					@project_1 = newProject
					# replacing a file should update the project structure
					expect(@project_1.version).to.equal(@project_0.version + 1)
					done()

	describe "moving entities", ->
		before (done) ->
