mirror of
https://github.com/nasa/openmct.git
synced 2025-06-19 07:38:15 +00:00
[Edit Mode] #627 removed edit concerns from browse controllers and markup
Fixed elements not appearing in edit mode Fixed failing tests
This commit is contained in:
@ -84,6 +84,24 @@ define(
|
||||
expect(callback).not.toHaveBeenCalled();
|
||||
});
|
||||
|
||||
it("adds listeners to the 'after' state by default", function(){
|
||||
expect(navigationService.callbacks.after).toBeUndefined();
|
||||
navigationService.addListener(function(){});
|
||||
expect(navigationService.callbacks.after).toBeDefined();
|
||||
expect(navigationService.callbacks.after.length).toBe(1);
|
||||
});
|
||||
|
||||
it("allows navigationService events to be prevented", function(){
|
||||
var callback = jasmine.createSpy("callback"),
|
||||
navigationResult;
|
||||
callback.andReturn(false);
|
||||
navigationService.addListener(callback, "before");
|
||||
navigationResult = navigationService.setNavigation({});
|
||||
expect(callback).toHaveBeenCalled();
|
||||
expect(navigationResult).toBe(false);
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
}
|
||||
);
|
||||
);
|
||||
|
Reference in New Issue
Block a user