How to mock route.snapshot.params?
Ok, I've found how to mock ActivatedRoute snapshot in the simple way. Something like this works for me:
providers: [MyComponent, { provide: ActivatedRoute, useValue: {snapshot: {params: {'myId': '123'}}}}
Thanks :)
If using route.snapshot.paramMap.get( 'uuid' ) instead:
import { ActivatedRoute, convertToParamMap } from '@angular/router';{ provide: ActivatedRoute, useValue: { snapshot: { paramMap: convertToParamMap( { 'uuid': '99-88-77' } ) } }}