nativescript-angular
nativescript-angular copied to clipboard
[QUESTION] How would you write unit test on a function that uses RouterExtensions from “nativescript-angular/router” for navigation
I have a login function that navigates user to home page on succesfull login
login() {
if(this.user){
this.processing = false;
this.routerExtensions.navigate(["/home"], { clearHistory: true });
}else{
this.processing = false;
this.alert("Unfortunately we could not find your account.");
}
}
A comprehensive understanding of the question can be found here stackoverflow.
HI @Denniskamau, You can review our test app here and to use it as a reference.
:wave: @Denniskamau, we use the issue tracker exclusively for bug reports and feature requests. However, this issue appears to be a support request. Please, use Stackoverflow to get help.