You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We found a way to inject an instance of knora-api-connection and spy on one method in the knora-api-js-lib. However, this is not ideal and the MockFactory should provide a simpler way to get test data and call endpoint methods (e.g. getProjects()).
In this example, we create the spy in the beforeEach() because the method to get projects in the component is triggered in ngOnInit().
We found a way to inject an instance of knora-api-connection and spy on one method in the knora-api-js-lib. However, this is not ideal and the MockFactory should provide a simpler way to get test data and call endpoint methods (e.g. getProjects()).
In this example, we create the spy in the beforeEach() because the method to get projects in the component is triggered in ngOnInit().
main.component.ts
main.component.spec.ts
The text was updated successfully, but these errors were encountered: