angular2-testing Questions

1

Solved

Starting out with angular 2 after spending time with angular 1. Not having unit tested this much as it's more of a side project thing, I'm trying at least start out OK... I started with the example...
Nibble asked 29/9, 2016 at 12:30

1

Solved

First, I understand that I should not be testing a private method, however I feel there are times that I should test if a private method was called based on some logic. I'm building a wrapper ser...
Villein asked 21/9, 2016 at 18:0

1

Solved

So I am testing my angular2 components & services. So far I have used mockBackend for mocking get request in service as below: /* tslint:disable:no-unused-variable */ import { MockBackend } ...
Hardcastle asked 9/9, 2016 at 7:35

1

Solved

My method under test is the following: /** * Update properties when the applicant changes the payment term value. * @return {Mixed} - Either an Array where the first index is a boolean indicati...
Adolfoadolph asked 14/9, 2016 at 1:45

2

So, in version RC5 of Angular2, they deprecated the HTTP_PROVIDERS and introduced the HttpModule. For my application code, this is working fine, but I'm struggling to make the change in my Jasmine ...
Wellintentioned asked 11/8, 2016 at 18:23

1

Solved

I am trying to test a structural directive named MyDirective with Jasmine. The Angular version used is RC5. // Part of the MyDirective class @Directive({selector: '[myDirective]'}) export class M...
Quaternion asked 11/9, 2016 at 12:44

1

Solved

I am using RC3. I am implementing the new Angular2 router as documented here: https://angular.io/docs/ts/latest/guide/router.html Everything works fine but I am having problem in unit testing. Spec...
Violaviolable asked 28/6, 2016 at 15:38

2

Can anyone help me with testing Http requests in Angular 2. I have a service that gets a stream from two http requests. How do I mock this behaviour in my test? loadData() { return Observable.for...
Continuator asked 18/3, 2016 at 16:24

© 2022 - 2024 — McMap. All rights reserved.