[ADF-3586] Add processInstanceId input and fix empty response (#3916)

* [ADF-3586] Add processInstanceId input and fix empty response

* [ADF-3586] Fix Task Details Model

* [ADF-3586] Fix Dates on ProcessList Component

* [ADF-3586] Fix Task Details Model

* [ADF-3586] Fix attach form unit tests

* [ADF-3586] Fix moment.js import

* [ADF-3586] Remove fdescribe

* [ADF-3586] Fix Attach Form Component unit test
This commit is contained in:
davidcanonieto
2018-11-19 14:57:26 +00:00
committed by Eugenio Romano
parent f0dff4d011
commit 3d0c7449b4
8 changed files with 81 additions and 43 deletions

View File

@@ -185,15 +185,14 @@ describe('ProcessInstanceListComponent', () => {
expect(dataRow[0]['id']).toEqual('999');
});
it('should throw an exception when the response is wrong', fakeAsync(() => {
let emitSpy: jasmine.Spy = spyOn(component.error, 'emit');
it('should return an empty list when the response is wrong', fakeAsync(() => {
let mockError = 'Fake server error';
getProcessInstancesSpy.and.returnValue(throwError(mockError));
component.appId = 1;
component.state = 'open';
fixture.detectChanges();
tick();
expect(emitSpy).toHaveBeenCalledWith(mockError);
expect(component.isListEmpty()).toBeTruthy();
}));
it('should emit onSuccess event when reload() called', fakeAsync(() => {