 		beforeEach ->
 			@path = "/path/to/file"
 
-			@newFile = {_id: file_id, rev: 0, name: @fileName}
+			@newFile = {_id: file_id, rev: 0, name: @fileName, linkedFileData: @linkedFileData}
 			@TpdsUpdateSender.addFile = sinon.stub().yields()
 			@ProjectEntityMongoUpdateHandler.addFile = sinon.stub().yields(null, {path: fileSystem: @path}, @project)
 			@ProjectEntityUpdateHandler.addFile project_id, folder_id, @fileName, @fileSystemPath, @linkedFileData, userId, @callback

				else
					@._id = file_id
				@rev = 0

		@docName = "doc-name"
		@docLines = ['1234','abc']

			@newFileUrl = "new-file-url"
			@FileStoreHandler.uploadFileFromDisk = sinon.stub().yields(null, @newFileUrl)

			@newFile = _id: new_file_id, name: "dummy-upload-filename", rev: 0, linkedFileData: @linkedFileData
			@oldFile = _id: file_id
			@path = "/path/to/file"
			@ProjectEntityMongoUpdateHandler._insertDeletedFileReference = sinon.stub().yields()
