MockLocationStrategy

Stable Class

Class Overview

class MockLocationStrategy {
  constructor()
  
  
  internalBaseHref : string
  internalPath : string
  internalTitle : string
  urlChanges : string[]
  simulatePopState(url: string) : void
  path(includeHash?: boolean) : string
  prepareExternalUrl(internal: string) : string
  pushState(ctx: any, title: string, path: string, query: string) : void
  replaceState(ctx: any, title: string, path: string, query: string) : void
  onPopState(fn: (value: any) => void) : void
  getBaseHref() : string
  back() : void
  forward() : void
}

Class Description

A mock implementation of LocationStrategy that allows tests to fire simulated location events.

Annotations

@Injectable()

Constructor

constructor()

Class Details

internalBaseHref : string
internalPath : string
internalTitle : string
urlChanges : string[]
simulatePopState(url: string) : void
path(includeHash?: boolean) : string
prepareExternalUrl(internal: string) : string
pushState(ctx: any, title: string, path: string, query: string) : void
replaceState(ctx: any, title: string, path: string, query: string) : void
onPopState(fn: (value: any) => void) : void
getBaseHref() : string
back() : void
forward() : void

exported from @angular/common/testing/index, defined in @angular/common/testing/mock_location_strategy.ts

doc_Angular
2016-10-06 09:46:43
Comments
Leave a Comment

Please login to continue.