[Edit Mode] Renamed function from EditAction.cancel() to EditAction.finish()

This commit is contained in:
Henry 2016-09-22 17:34:53 -07:00
parent 275dda820b
commit 98f387b605
2 changed files with 4 additions and 4 deletions

View File

@ -64,7 +64,7 @@ define(
var editing = currentObject.hasCapability('editor') &&
currentObject.getCapability('editor').isEditContextRoot();
return self.$q.when(editing && currentObject.getCapability("editor").cancel());
return self.$q.when(editing && currentObject.getCapability("editor").finish());
}
function navigate() {

View File

@ -61,7 +61,7 @@ define(
capabilities.editor = jasmine.createSpyObj("editorCapability", [
"isEditContextRoot",
"cancel"
"finish"
]);
mockNavigatedObject.getCapability.andCallFake(function (capability) {
@ -148,9 +148,9 @@ define(
capabilities.editor.isEditContextRoot.andReturn(true);
});
it("cancels editing if in edit mode", function () {
it("finishes editing if in edit mode", function () {
action.perform();
expect(capabilities.editor.cancel)
expect(capabilities.editor.finish)
.toHaveBeenCalled();
});
});