Skip to content

Commit 6076e41

Browse files
feat(data): Introduce Standalone API for NgRx Data
1 parent b00798d commit 6076e41

File tree

2 files changed

+4
-12
lines changed

2 files changed

+4
-12
lines changed

modules/data/spec/entity-services/entity-collection-service.spec.ts

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ import {
2929
Logger,
3030
} from '../..';
3131

32-
// TODO fix these tests
3332
describe('EntityCollectionService', () => {
3433
describe('Command dispatching', () => {
3534
// Borrowing the dispatcher tests from entity-dispatcher.spec.
@@ -134,16 +133,9 @@ describe('EntityCollectionService', () => {
134133
const httpError = { error: new Error('Test Failure'), status: 501 };
135134
const error = makeDataServiceError('GET', httpError);
136135
dataService.setErrorResponse('getWithQuery', error);
137-
heroCollectionService.getWithQuery({ name: 'foo' }).subscribe(
138-
() => {
139-
console.log('expected error', error);
140-
expectErrorToBe(error, done);
141-
},
142-
(err) => {
143-
console.log('actual error', err);
144-
expectErrorToBe(error, done);
145-
}
146-
);
136+
heroCollectionService
137+
.getWithQuery({ name: 'foo' })
138+
.subscribe(expectErrorToBe(error, done));
147139
});
148140

149141
it('load observable should emit heroes on success', (done: any) => {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
export const getGreeting = () => cy.get('h1');
2-
export const loadFeature = () => cy.get('a').contains('Load Feature').click();
2+
export const loadFeature = () => cy.get('a').click();

0 commit comments

Comments
 (0)