{"version":3,"file":"ngworker-spectacular.mjs","sources":["../../../../packages/spectacular/src/lib/shared/app-component/spectacular-app.component.ts","../../../../packages/spectacular/src/lib/application-testing/util-dom/create-template.ts","../../../../packages/spectacular/src/lib/application-testing/util-dom/is-template-element.ts","../../../../packages/spectacular/src/lib/application-testing/util-dom/get-content.ts","../../../../packages/spectacular/src/lib/application-testing/util-dom/create-element.ts","../../../../packages/spectacular/src/lib/application-testing/util-dom/detach.ts","../../../../packages/spectacular/src/lib/application-testing/util-dom/replace-root-element.ts","../../../../packages/spectacular/src/lib/application-testing/util-dom/ensure-fresh-root-element.ts","../../../../packages/spectacular/src/lib/application-testing/util-bootstrapping/bootstrap-component.ts","../../../../packages/spectacular/src/lib/application-testing/util-bootstrapping/run-platform-initializers.ts","../../../../packages/spectacular/src/lib/application-testing/util-bootstrapping/wait-for-application-initializers.ts","../../../../packages/spectacular/src/lib/application-testing/application-harness/create-application-harness.ts","../../../../packages/spectacular/src/lib/feature-testing/configuration/feature-path.token.ts","../../../../packages/spectacular/src/lib/feature-testing/util-text/ensure-leading-character.ts","../../../../packages/spectacular/src/lib/feature-testing/util-text/trim-leading-text.ts","../../../../packages/spectacular/src/lib/feature-testing/navigation/relative-feature-url-prefix.ts","../../../../packages/spectacular/src/lib/feature-testing/navigation/spectacular-feature-location.ts","../../../../packages/spectacular/src/lib/feature-testing/navigation/spectacular-feature-router.ts","../../../../packages/spectacular/src/lib/feature-testing/configuration/provide-spectacular-feature-testing.ts","../../../../packages/spectacular/src/lib/feature-testing/configuration/spectacular-feature-testing-features.ts","../../../../packages/spectacular/src/lib/feature-testing/navigation/initial-feature-navigation.initializer.ts","../../../../packages/spectacular/src/lib/feature-testing/configuration/make-spectacular-feature-testing-feature.ts","../../../../packages/spectacular/src/lib/feature-testing/configuration/with-initial-feature-navigation.ts","../../../../packages/spectacular/src/lib/feature-testing/feature-harness/create-feature-harness.ts","../../../../packages/spectacular/src/lib/pipe-testing/pipe-component/spectacular-pipe.component.ts","../../../../packages/spectacular/src/lib/pipe-testing/pipe-harness/create-pipe-harness.ts","../../../../packages/spectacular/src/lib/pipe-testing/pipe-harness/spectacular-pipe-harness.ts","../../../../packages/spectacular/src/index.ts","../../../../packages/spectacular/src/ngworker-spectacular.ts"],"sourcesContent":["import { Component, ViewChild } from '@angular/core';\nimport { RouterOutlet } from '@angular/router';\n\n/**\n * The tag name of `SpectacularAppComponent`'s DOM element.\n */\nexport const spectacularAppTag = 'spectacular-app';\n\n/**\n * The root component which is bootstrapped for a Spectacular test.\n */\n@Component({\n  standalone: true,\n  selector: spectacularAppTag,\n  imports: [RouterOutlet],\n  template: '<router-outlet></router-outlet>',\n})\nexport class SpectacularAppComponent {\n  /**\n   * The router outlet of the root component.\n   *\n   * @see `getActiveComponent`.\n   */\n  @ViewChild(RouterOutlet)\n  routerOutlet?: RouterOutlet;\n\n  /**\n   * Get the active top-level routed component, for example a page component.\n   */\n  getActiveComponent<TActiveComponent>(): TActiveComponent {\n    if (!this.routerOutlet) {\n      throw new Error(\n        'SpectacularAppComponent#getActiveComponent called before its view child is available.'\n      );\n    }\n\n    return this.routerOutlet.component as TActiveComponent;\n  }\n}\n","import { DOCUMENT } from '@angular/common';\nimport { TestBed } from '@angular/core/testing';\n\n/**\n * Wrap the specified HTML in a template.\n *\n * @param html The markup to embed in the template.\n * @returns The template wrapping the specified markup.\n */\nexport function createTemplate(html: string): HTMLElement {\n  const doc = TestBed.inject(DOCUMENT);\n\n  const templateElement = doc.createElement('template');\n  templateElement.innerHTML = html;\n\n  return templateElement;\n}\n","/**\n * Detects whether the specified DOM node is a template element.\n *\n * @param node The potential template element.\n * @returns `true` if the specified DOM node is a template element, otherwise\n *   `false`.\n */\nexport function isTemplateElement(node: Node): node is HTMLTemplateElement {\n  return 'content' in node;\n}\n","import { isTemplateElement } from './is-template-element';\n\n/**\n * Extract the DOM elements from the specified DOM node. If it's a template,\n * extract its DOM fragment.\n *\n * @param node The DOM node whose DOM elements to extract.\n * @returns The DOM elements of the specified DOM node.\n */\nexport function getContent(node: Node): Node {\n  return isTemplateElement(node) ? node.content : node;\n}\n","import { createTemplate } from './create-template';\nimport { getContent } from './get-content';\n\n/**\n * Create an element with the specified tag name.\n *\n * @param tagName The tag name of the element to create.\n */\nexport function createElement(tagName: string): HTMLElement {\n  return getContent(createTemplate(`<${tagName}></${tagName}>`))\n    .firstChild as HTMLElement;\n}\n","/**\n * Detach the specified DOM node from any document or document fragment it's\n * attached to.\n *\n * @param node The DOM node to detach.\n */\nexport function detach(node: Node): void {\n  node.parentNode?.removeChild(node);\n}\n","import { DOCUMENT } from '@angular/common';\nimport { TestBed } from '@angular/core/testing';\n\nimport { detach } from './detach';\n\n/**\n * Detach all instances sharing the tag name of the sepcified element from the\n * DOM, then attach the specified element.\n *\n * @param newRootElement The root element to attach.\n */\nexport function replaceRootElement(newRootElement: HTMLElement): void {\n  const doc = TestBed.inject(DOCUMENT);\n\n  doc\n    .querySelectorAll(newRootElement.tagName)\n    .forEach(oldRootElement => detach(oldRootElement));\n  doc.body.appendChild(newRootElement);\n}\n","import { createElement } from './create-element';\nimport { replaceRootElement } from './replace-root-element';\n\n/**\n * Make sure that we have a new root element attached to the DOM.\n *\n * @param tagName The tag name of the element to create and attach.\n */\nexport function ensureFreshRootElement(tagName: string): void {\n  const rootElement = createElement(tagName);\n\n  replaceRootElement(rootElement);\n}\n","import type { Type } from '@angular/core';\nimport { ApplicationRef } from '@angular/core';\nimport { ComponentFixture, TestBed } from '@angular/core/testing';\nimport { ensureFreshRootElement } from '../util-dom/ensure-fresh-root-element';\n\nexport interface BootstrapComponentOptions<TRootComponent> {\n  readonly component: Type<TRootComponent>;\n  readonly tag: string;\n}\n\n/**\n * Create and attach a root element with the specified tag name to the DOM, then\n * bootstrap a component of the specified type.\n *\n * @param rootTag The tag name of the root element.\n * @param rootComponent The root component type.\n */\nexport async function bootstrapComponent<TRootComponent>({\n  component,\n  tag,\n}: BootstrapComponentOptions<TRootComponent>): Promise<\n  ComponentFixture<TRootComponent>\n> {\n  ensureFreshRootElement(tag);\n  const application = TestBed.inject(ApplicationRef);\n  const componentRef = application.bootstrap(component, tag);\n  const fixture = TestBed.runInInjectionContext(\n    () => new ComponentFixture<TRootComponent>(componentRef)\n  );\n\n  return fixture;\n}\n","import { PLATFORM_INITIALIZER } from '@angular/core';\nimport { TestBed } from '@angular/core/testing';\n\n/**\n * Run platform initializers.\n */\nexport function runPlatformInitializers(): void {\n  const initializers = TestBed.inject(PLATFORM_INITIALIZER, [], {\n    optional: true,\n  });\n\n  initializers.forEach(initializer => initializer());\n}\n","import { ApplicationInitStatus } from '@angular/core';\nimport { TestBed } from '@angular/core/testing';\n\n/**\n * Wait for application initializers to complete.\n */\nexport async function waitForApplicationInitializers(): Promise<void> {\n  const applicationInitStatus = TestBed.inject(ApplicationInitStatus);\n\n  await applicationInitStatus.donePromise;\n}\n","import { provideLocationMocks } from '@angular/common/testing';\nimport type { NgModule } from '@angular/core';\nimport { TestBed } from '@angular/core/testing';\nimport {\n  SpectacularAppComponent,\n  spectacularAppTag,\n} from '../../shared/app-component/spectacular-app.component';\nimport { bootstrapComponent } from '../util-bootstrapping/bootstrap-component';\nimport { runPlatformInitializers } from '../util-bootstrapping/run-platform-initializers';\nimport { waitForApplicationInitializers } from '../util-bootstrapping/wait-for-application-initializers';\nimport { SpectacularApplicationHarness } from './spectacular-application-harness';\n\n/**\n * Application harness options.\n */\nexport type CreateApplicationHarnessOptions = Pick<\n  NgModule,\n  'imports' | 'providers'\n>;\n\n/**\n * Bootstrap a test application with the specified metadata. Useful to test\n * configuration Angular modules, bootstrap listeners, and application\n * initializers.\n */\nexport async function createApplicationHarness(\n  options: CreateApplicationHarnessOptions = {}\n): Promise<SpectacularApplicationHarness> {\n  const { imports = [], providers = [] } = options;\n\n  TestBed.configureTestingModule({\n    imports: [...imports],\n    providers: [provideLocationMocks(), ...providers],\n  });\n\n  TestBed.compileComponents();\n\n  runPlatformInitializers();\n  await waitForApplicationInitializers();\n\n  const rootFixture = await bootstrapComponent({\n    component: SpectacularAppComponent,\n    tag: spectacularAppTag,\n  });\n\n  return {\n    inject: TestBed.inject.bind(TestBed),\n    get rootComponent() {\n      return rootFixture.componentInstance;\n    },\n    rootFixture,\n  };\n}\n","import type { Provider } from '@angular/core';\nimport { InjectionToken } from '@angular/core';\n\n/**\n * Internal dependency used to pass the feature route path to Spectacular\n * feature testing services.\n */\nexport const featurePathToken = new InjectionToken<string>(\n  '__SPECTACULAR_INTERNAL_FEATURE_PATH__'\n);\n\nexport function provideFeaturePath(featurePath: string): Provider {\n  return {\n    provide: featurePathToken,\n    useValue: featurePath,\n  };\n}\n","export function ensureLeadingCharacter(\n  leadingCharacter: string,\n  text: string\n): string {\n  if (text === '') {\n    text = leadingCharacter;\n  } else if (text.substr(0, 1) !== leadingCharacter) {\n    text = leadingCharacter + text;\n  }\n\n  return text;\n}\n","export function trimLeadingText(\n  leadingText: string,\n  originalText: string\n): string {\n  const leadingTextCharacterCount = leadingText.length;\n\n  while (originalText.substr(0, leadingTextCharacterCount) === leadingText) {\n    originalText = originalText.substr(leadingTextCharacterCount);\n  }\n\n  return originalText;\n}\n","/**\n * The URL prefix used by Spectacular feature testing services to indicate a\n * route relative to the Angular feature module under test.\n */\nexport const relativeFeatureUrlPrefix = '~';\n","import { Location } from '@angular/common';\nimport { inject, Injectable } from '@angular/core';\nimport { featurePathToken } from '../configuration/feature-path.token';\nimport { ensureLeadingCharacter } from '../util-text/ensure-leading-character';\nimport { trimLeadingText } from '../util-text/trim-leading-text';\nimport { relativeFeatureUrlPrefix } from './relative-feature-url-prefix';\n\n/**\n * A subset of Angular's `Location` service adjusted to the Angular feature\n * module under test.\n */\n@Injectable()\nexport class SpectacularFeatureLocation {\n  readonly #featurePath = inject(featurePathToken);\n  readonly #location = inject(Location);\n\n  /**\n   * Normalizes the URL path for this location. URLs within the Angular feature\n   * module under test are prefixed with tilde (`~`).\n   *\n   * Wraps `Location#path`.\n   *\n   * @param includeHash True to include an anchor fragment in the path.\n   *   Optional. Default is `false`.\n   */\n  path(includeHash = false): string {\n    const path = this.#location.path(includeHash);\n    const strippedPath = trimLeadingText('/' + this.#featurePath, path);\n    const isOutsideFeature = strippedPath === path;\n\n    if (isOutsideFeature) {\n      return path;\n    }\n\n    return ensureLeadingCharacter(\n      relativeFeatureUrlPrefix,\n      ensureLeadingCharacter('/', strippedPath)\n    );\n  }\n}\n","import { inject, Injectable, NgZone } from '@angular/core';\nimport type { NavigationExtras, UrlTree } from '@angular/router';\nimport { Router, UrlSegment } from '@angular/router';\nimport { featurePathToken } from '../configuration/feature-path.token';\nimport { ensureLeadingCharacter } from '../util-text/ensure-leading-character';\nimport { relativeFeatureUrlPrefix } from './relative-feature-url-prefix';\n\n/**\n * A subset of Angular's `Router` server adjusted to the Angular feature module\n * under test.\n */\n@Injectable()\nexport class SpectacularFeatureRouter {\n  readonly #featurePath = inject(featurePathToken);\n  readonly #router = inject(Router);\n  readonly #ngZone = inject(NgZone);\n\n  /**\n   * Navigate based on the provided array of commands and a starting point. If\n   * no starting route is provided, the navigation is absolute.\n   *\n   * If the first command is a tilde (`~`), the navigation is relative to the\n   * feature under test.\n   *\n   * Wraps `Router#navigate`.\n   *\n   * @param commands An array of URL fragments with which to construct the\n   *   target URL. If the path is static, can be the literal URL string. For a\n   *   dynamic path, pass an array of path segments, followed by the parameters\n   *   for each segment. The fragments are applied to the current URL or the one\n   *   provided in the relativeTo property of the options object, if supplied.\n   *   If the first command is a tilde (`~`), the navigation is relative to the\n   *   feature under test.\n   * @param extras An options object that determines how the URL should be\n   *   constructed or interpreted. Optional. Default is `{ skipLocationChange: false }`.\n   */\n  // eslint-disable-next-line @typescript-eslint/no-explicit-any\n  navigate(commands: any[], extras?: NavigationExtras): Promise<boolean> {\n    const [head, ...tail] = commands;\n\n    if (head === relativeFeatureUrlPrefix) {\n      commands = [this.#featurePath, ...tail];\n    }\n\n    return this.#ngZone.run(() => this.#router.navigate(commands, extras));\n  }\n\n  /**\n   * Navigates to a view using an absolute route path.\n   *\n   * If the URL is prefixed with tilde (`~`), the navigation is relative to the\n   * feature under test.\n   *\n   * Wraps `Router#navigateByUrl`.\n   *\n   * @param url An absolute path for a defined route. The function does not\n   *   apply any delta to the current URL. If the URL is prefixed with tilde\n   *   (`~`), the navigation is relative to the feature under test.\n   * @param extras An object containing properties that modify the navigation\n   *   strategy. Optional. Default is `{ skipLocationChange: false }`.\n   */\n  navigateByUrl(\n    url: string | UrlTree,\n    extras?: NavigationExtras\n  ): Promise<boolean> {\n    if (typeof url !== 'string') {\n      // url is UrlTree\n\n      const isRelativeFeatureUrlTree =\n        url.root.children['primary']?.segments[0].path === '~';\n\n      if (isRelativeFeatureUrlTree) {\n        const [, ...tail] = url.root.children['primary'].segments;\n        const featureSegment = new UrlSegment(this.#featurePath, {});\n        url.root.children['primary'].segments = [featureSegment, ...tail];\n      }\n\n      url = this.#router.serializeUrl(url);\n    }\n\n    const needle = relativeFeatureUrlPrefix + '/';\n\n    if (url.startsWith(needle)) {\n      url = url.substr(needle.length);\n      url = this.#prependFeaturePath(url);\n    }\n\n    return this.#ngZone.run(() => this.#router.navigateByUrl(url, extras));\n  }\n\n  #prependFeaturePath(url: string): string {\n    return (\n      this.#router.serializeUrl(this.#router.parseUrl(this.#featurePath)) +\n      ensureLeadingCharacter('/', url)\n    );\n  }\n}\n","import { provideLocationMocks } from '@angular/common/testing';\nimport type { EnvironmentProviders, Provider } from '@angular/core';\nimport type { RouterFeatures, Routes } from '@angular/router';\nimport { provideRouter } from '@angular/router';\nimport { SpectacularFeatureLocation } from '../navigation/spectacular-feature-location';\nimport { SpectacularFeatureRouter } from '../navigation/spectacular-feature-router';\nimport { provideFeaturePath } from './feature-path.token';\nimport type { SpectacularFeatureTestingFeatures } from './spectacular-feature-testing-features';\n\n/**\n * Options for {@link provideSpectacularFeatureTesting}.\n */\nexport interface ProvideSpectacularFeatureTestingOptions {\n  /**\n   * The path prefix used to load the routes of the specified Angular feature,\n   * for example `'heroes'`.\n   */\n  readonly featurePath: string;\n  /**\n   * One or more feature routes to load.\n   *\n   * NOTE! It is unnecessary to lazy-load feature modules in tests, so we can\n   * statically return an Angular module from the `loadChildren` callback.\n   *\n   * @example\n   * ```typescript\n   * [{ path: 'heroes', loadChildren: () => HeroesModule }]\n   * ```\n   */\n  readonly routes: Routes;\n}\n\n/**\n * Provide dependencies needed by the Spectacular Feature testing API.\n */\nexport function provideSpectacularFeatureTesting(\n  options: ProvideSpectacularFeatureTestingOptions,\n  ...features: (SpectacularFeatureTestingFeatures | RouterFeatures)[]\n): (EnvironmentProviders | Provider)[] {\n  const { featurePath, routes } = options;\n\n  return [\n    provideFeaturePath(featurePath),\n    provideRouter(routes),\n    features.map(feature => feature.ɵproviders),\n    provideLocationMocks(),\n    SpectacularFeatureLocation,\n    SpectacularFeatureRouter,\n  ];\n}\n","import type { Provider } from '@angular/core';\n// Resolve @typescript-eslint/no-unused-vars: Used for TSDoc `@link` annotations.\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nimport { provideSpectacularFeatureTesting } from './provide-spectacular-feature-testing';\nimport type { InitialFeatureNavigationFeature } from './with-initial-feature-navigation';\n\n/**\n * The list of tree-shakable Spectacular Feature Testing features as a union\n * type to uniquely type each feature.\n */\nexport enum SpectacularFeatureTestingFeatureKind {\n  InitialFeatureNavigationFeature = 'InitialFeatureNavigationFeature',\n}\n\n/**\n * A type that represents a tree-shakable Spectacular Feature Testing feature.\n */\nexport interface SpectacularFeatureTestingFeature<\n  TFeatureKind extends SpectacularFeatureTestingFeatureKind\n> {\n  /**\n   * For debugging purposes.\n   *\n   * @internal\n   */\n  readonly ɵbrand: 'SpectacularFeatureTestingFeature';\n  /**\n   * The feature name.\n   *\n   * @example 'InitialFeatureNavigationFeature'\n   *\n   * @internal\n   */\n  readonly ɵkind: TFeatureKind;\n  /**\n   * Feature providers.\n   *\n   * @internal\n   */\n  readonly ɵproviders: Provider[];\n}\n\n/**\n * A type alias that represents all tree-shakable Spectacular Feature Testing\n * features available for use with {@link provideSpectacularFeatureTesting}.\n * Features can be enabled by adding special functions to the {@link provideSpectacularFeatureTesting}\n * call.\n *\n * See documentation for each symbol to find its corresponding function name.\n * See also {@link provideSpectacularFeatureTesting} documentation on how to use\n * those functions.\n *\n * @see {@link provideSpectacularFeatureTesting}\n */\nexport type SpectacularFeatureTestingFeatures = InitialFeatureNavigationFeature;\n","import type { FactoryProvider } from '@angular/core';\nimport { APP_INITIALIZER } from '@angular/core';\nimport { fakeAsync, tick } from '@angular/core/testing';\nimport { featurePathToken } from '../configuration/feature-path.token';\nimport { SpectacularFeatureRouter } from './spectacular-feature-router';\n\n/**\n * Navigate to the default feature route.\n */\nasync function initialFeatureNavigation(\n  featureRouter: SpectacularFeatureRouter,\n  featurePath: string\n): Promise<void> {\n  const didNavigationSucceed = await featureRouter.navigate([featurePath]);\n\n  if (!didNavigationSucceed) {\n    throw new Error(`Navigation to \"/${featurePath}\" failed.`);\n  }\n}\n\n/**\n * Navigate to the default feature route, synchronously.\n */\nfunction initialFeatureNavigationFactory(\n  featureRouter: SpectacularFeatureRouter,\n  featurePath: string\n): () => void {\n  const initialFeatureNavigationSync = fakeAsync(() => {\n    initialFeatureNavigation(featureRouter, featurePath);\n    tick();\n  });\n\n  return () => initialFeatureNavigationSync();\n}\n\n/**\n * Navigate to the default feature route.\n */\nexport const initialFeatureNavigationInitializer: FactoryProvider = {\n  deps: [SpectacularFeatureRouter, featurePathToken],\n  multi: true,\n  provide: APP_INITIALIZER,\n  useFactory: initialFeatureNavigationFactory,\n};\n","import type { Provider } from '@angular/core';\nimport type {\n  SpectacularFeatureTestingFeature,\n  SpectacularFeatureTestingFeatureKind,\n} from './spectacular-feature-testing-features';\n\nexport function makeSpectacularFeatureTestingFeature<\n  TFeatureKind extends SpectacularFeatureTestingFeatureKind\n>(\n  kind: TFeatureKind,\n  providers: Provider[]\n): SpectacularFeatureTestingFeature<TFeatureKind> {\n  return {\n    ɵbrand: 'SpectacularFeatureTestingFeature',\n    ɵkind: kind,\n    ɵproviders: providers,\n  };\n}\n","import { initialFeatureNavigationInitializer } from '../navigation/initial-feature-navigation.initializer';\nimport { makeSpectacularFeatureTestingFeature } from './make-spectacular-feature-testing-feature';\n// Resolve @typescript-eslint/no-unused-vars: Used for TSDoc `@link` annotations.\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nimport { provideSpectacularFeatureTesting } from './provide-spectacular-feature-testing';\nimport type { SpectacularFeatureTestingFeature } from './spectacular-feature-testing-features';\nimport { SpectacularFeatureTestingFeatureKind } from './spectacular-feature-testing-features';\n\n/**\n * A type alias that represents a feature which enables initial navigation to\n * the specified feature path.\n *\n * The type is used to describe the return value of the {@link withInitialFeatureNavigation}\n * function.\n *\n * @see {@link withInitialFeatureNavigation}\n * @see {@link provideSpectacularFeatureTesting}\n */\nexport type InitialFeatureNavigationFeature =\n  SpectacularFeatureTestingFeature<SpectacularFeatureTestingFeatureKind.InitialFeatureNavigationFeature>;\n\n/**\n * Navigate to the specified feature path when the test is initialized.\n *\n * @example\n * ```typescript\n * providers: [\n *   provideSpectacularFeatureTesting(\n *     {\n *       featurePath: 'heroes',\n *       routes: [\n *         { path: 'heroes', loadChildren: () => heroesRoutes },\n *       ],\n *     },\n *     withInitialFeatureNavigation(),\n *   ),\n * ],\n * ```\n */\nexport function withInitialFeatureNavigation(): InitialFeatureNavigationFeature {\n  return makeSpectacularFeatureTestingFeature(\n    SpectacularFeatureTestingFeatureKind.InitialFeatureNavigationFeature,\n    [initialFeatureNavigationInitializer]\n  );\n}\n","import type { NgModule } from '@angular/core';\nimport { TestBed } from '@angular/core/testing';\nimport { ExtraOptions, Routes, withRouterConfig } from '@angular/router';\nimport { SpectacularAppComponent } from '../../shared/app-component/spectacular-app.component';\nimport { provideSpectacularFeatureTesting } from '../configuration/provide-spectacular-feature-testing';\nimport { withInitialFeatureNavigation } from '../configuration/with-initial-feature-navigation';\nimport { SpectacularFeatureLocation } from '../navigation/spectacular-feature-location';\nimport { SpectacularFeatureRouter } from '../navigation/spectacular-feature-router';\nimport type { SpectacularFeatureHarness } from './spectacular-feature-harness';\n\n/**\n * Feature harness options.\n */\nexport interface CreateFeatureHarnessOptions\n  extends Pick<NgModule, 'imports' | 'providers'> {\n  /**\n   * The route path used to load the routes of the specified Angular feature\n   * module, for example `'heroes'`.\n   */\n  readonly featurePath: string;\n  /**\n   * Optional Angular `Router` options.\n   */\n  readonly routerOptions?: ExtraOptions;\n  /**\n   * One or more feature routes to load.\n   *\n   * NOTE! It is unnecessary to lazy-load feature modules in tests, so we can\n   * statically return an Angular module from the `loadChildren` callback.\n   *\n   * @example\n   * ```typescript\n   * [{ path: 'heroes', loadChildren: () => HeroesModule }]\n   * ```\n   */\n  readonly routes: Routes;\n}\n\n/**\n * Configure feature testing environment, bootstrap `SpectacularAppComponent`,\n * and navigate to the default feature route.\n */\nexport function createFeatureHarness(\n  options: CreateFeatureHarnessOptions\n): SpectacularFeatureHarness {\n  const {\n    featurePath,\n    imports = [],\n    providers = [],\n    routerOptions = {},\n    routes,\n  } = options;\n\n  TestBed.configureTestingModule({\n    imports: [...imports],\n    providers: [\n      ...providers,\n      provideSpectacularFeatureTesting(\n        {\n          featurePath,\n          routes,\n        },\n        withInitialFeatureNavigation(),\n        withRouterConfig(routerOptions)\n      ),\n    ],\n  });\n  // NOTE(LayZeeDK): We might want to convert this to an asynchronous function\n  //   to support non-Angular CLI setups. Some of them might not be able to\n  //   handle running this statement synchronously.\n  TestBed.compileComponents();\n\n  const rootFixture = TestBed.createComponent(SpectacularAppComponent);\n  const location = TestBed.inject(SpectacularFeatureLocation);\n  const router = TestBed.inject(SpectacularFeatureRouter);\n\n  rootFixture.autoDetectChanges(true);\n\n  return {\n    inject: TestBed.inject.bind(TestBed),\n    location,\n    get rootComponent() {\n      return rootFixture.componentInstance;\n    },\n    rootFixture,\n    router,\n  };\n}\n","import { Component, Input } from '@angular/core';\nimport type { Observable } from 'rxjs';\n\n@Component({\n  standalone: true,\n  selector: 'spectacular-pipe',\n  imports: [],\n  template: '{{ value }}',\n})\nexport class SpectacularPipeComponent<TValue> {\n  @Input()\n  value: TValue | Observable<TValue> | null = null;\n}\n","import { isStandalone, NgModule, PipeTransform, Type } from '@angular/core';\nimport type { ComponentFixture } from '@angular/core/testing';\nimport { TestBed } from '@angular/core/testing';\nimport { By } from '@angular/platform-browser';\nimport type { Observable } from 'rxjs';\nimport { SpectacularPipeComponent } from '../pipe-component/spectacular-pipe.component';\nimport type { SpectacularPipeHarness } from './spectacular-pipe-harness';\n\n/**\n * Angular pipe harness options.\n */\nexport interface CreatePipeHarnessOptions<TValue>\n  extends Pick<NgModule, 'declarations' | 'imports' | 'providers'> {\n  /**\n   * The type of the Angular pipe-under-test, for example `CamelizePipe`.\n   */\n  readonly pipe: Type<PipeTransform>;\n  /**\n   * The name of the Angular pipe-under-test, for example `camelize`.\n   */\n  readonly pipeName: string;\n  /**\n   * The template used to test the Angular pipe, for example\n   * `'{{ value | camelize }}'`.\n   *\n   * NOTE! The `value` property is in context of the template.\n   */\n  readonly template?: string;\n  /**\n   * The initial value passed through the Angular pipe.\n   */\n  readonly value: Observable<TValue> | TValue | null;\n}\n\nfunction createPipeComponentTemplate(innerTemplate: string): string {\n  return `<span id=\"${textId}\">${innerTemplate}</span>`;\n}\n\nfunction createPipeFixture<TValue>(\n  value: Observable<TValue> | TValue | null\n): ComponentFixture<SpectacularPipeComponent<TValue>> {\n  const pipeFixture = TestBed.createComponent(\n    SpectacularPipeComponent\n  ) as ComponentFixture<SpectacularPipeComponent<TValue>>;\n  pipeFixture.componentInstance.value = value;\n  pipeFixture.detectChanges();\n\n  return pipeFixture;\n}\n\n/**\n * Set up a host component for the Angular pipe under test.\n *\n * Test it by updating the value and reading the rendered text.\n */\nexport function createPipeHarness<TValue>(\n  options: CreatePipeHarnessOptions<TValue>\n): SpectacularPipeHarness<TValue> {\n  function configureTestbed(template: string): void | never {\n    const isStandalonePipe = isStandalone(pipe);\n\n    TestBed.configureTestingModule({\n      declarations: [...declarations].concat(isStandalonePipe ? [] : [pipe]),\n      imports: [...imports].concat(isStandalonePipe ? [pipe] : []),\n      providers: [...providers],\n    });\n    TestBed.overrideTemplateUsingTestingModule(\n      SpectacularPipeComponent,\n      createPipeComponentTemplate(template)\n    );\n  }\n\n  const {\n    declarations = [],\n    imports = [],\n    pipe,\n    pipeName,\n    providers = [],\n    template = `{{ value | ${pipeName} }}`,\n    value,\n  } = options;\n\n  configureTestbed(template);\n  TestBed.compileComponents();\n\n  let pipeFixture = createPipeFixture(value);\n  let pipeComponent = pipeFixture.componentInstance;\n\n  return {\n    inject: TestBed.inject.bind(TestBed),\n    get text(): string {\n      const valueElement: HTMLElement = pipeFixture.debugElement.query(\n        By.css(`#${textId}`)\n      ).nativeElement;\n\n      return valueElement.textContent?.trim() ?? '';\n    },\n    set template(template: string) {\n      const value = pipeComponent.value;\n\n      TestBed.resetTestingModule();\n      configureTestbed(template);\n\n      pipeFixture = createPipeFixture(value);\n      pipeComponent = pipeFixture.componentInstance;\n    },\n    set value(value: TValue | Observable<TValue> | null) {\n      pipeComponent.value = value;\n      pipeFixture.detectChanges();\n    },\n  };\n}\n\nconst textId = '__SPECTACULAR_PIPE_COMPONENT_TEXT__';\n","import type { InjectFlags, InjectOptions, ProviderToken } from '@angular/core';\nimport type { Observable } from 'rxjs';\n\n/**\n * A harness for testing an Angular pipe.\n *\n * Includes an API to write a value and read the rendered text.\n */\nexport abstract class SpectacularPipeHarness<TValue> {\n  /**\n   * Replace the pipe component template.\n   *\n   * NOTE! The `value` property is in context of the specified template.\n   *\n   * @param template The component template used to test the Angular pipe, for\n   *   example `'{{ value | camelize }}'`.\n   */\n  abstract set template(template: string);\n  /**\n   * Read the text rendered in the pipe component template.\n   */\n  abstract get text(): string;\n  /**\n   * Update the value passed through the Angular pipe.\n   *\n   * @param value The new value.\n   */\n  abstract set value(value: TValue | Observable<TValue> | null);\n  /**\n   * Resolve a dependency based on the specified dependency injection token.\n   *\n   * @param token The token representing the dependency, that is a class or an\n   *   `InjectionToken`.\n   * @param notFoundValue The default value in case the specified dependency\n   *   has not been provided. Optional. Default is `null`.\n   * @param options Dependency injection options. Optional.\n   * @returns {T} The instance from the injector if defined, otherwise the `notFoundValue`.\n   * @throws {Error} When the `notFoundValue` is `undefined` or `Injector.THROW_IF_NOT_FOUND`\n   */\n  abstract inject<T>(\n    token: ProviderToken<T>,\n    notFoundValue: undefined,\n    options: InjectOptions & {\n      optional?: false;\n    }\n  ): T;\n  abstract inject<T>(\n    token: ProviderToken<T>,\n    notFoundValue: null | undefined,\n    options: InjectOptions\n  ): T | null;\n  abstract inject<T>(\n    token: ProviderToken<T>,\n    notFoundValue?: T,\n    options?: InjectOptions\n  ): T;\n  /**\n   * Resolve a dependency based on the specified dependency injection token.\n   *\n   * @param token The token representing the dependency, that is a class or an\n   *   `InjectionToken`.\n   * @param notFoundValue The default value in case the specified dependency\n   *   has not been provided. Optional. Default is `null`.\n   * @param flags Dependency injection options, for example\n   *   `InjectFlags.Optional | InjectFlags.SkipSelf`. Optional. Default is\n   *   `InjectFlags.Default`.\n   * @returns {T} The instance from the injector if defined, otherwise the `notFoundValue`.\n   * @throws {Error} When the `notFoundValue` is `undefined` or `Injector.THROW_IF_NOT_FOUND`\n   * @deprecated Use object-based flags (`InjectOptions`) instead.\n   */\n  abstract inject<T>(\n    token: ProviderToken<T>,\n    notFoundValue?: T,\n    flags?: InjectFlags\n  ): T;\n  /**\n   * Resolve a dependency based on the specified dependency injection token.\n   *\n   * @param token The token representing the dependency, that is a class or an\n   *   `InjectionToken`.\n   * @param notFoundValue The default value in case the specified dependency\n   *   has not been provided. Optional. Default is `null`.\n   * @param flags Dependency injection options, for example\n   *   `InjectFlags.Optional | InjectFlags.SkipSelf`. Optional. Default is\n   *   `InjectFlags.Default`.\n   * @returns {T} The instance from the injector if defined, otherwise the `notFoundValue`.\n   * @throws {Error} When the `notFoundValue` is `undefined` or `Injector.THROW_IF_NOT_FOUND`\n   * @deprecated Use object-based flags (`InjectOptions`) instead.\n   */\n  abstract inject<T>(\n    token: ProviderToken<T>,\n    notFoundValue: null,\n    flags?: InjectFlags\n  ): T | null;\n}\n","// Application testing API\nexport * from './lib/application-testing/application-harness/create-application-harness';\nexport * from './lib/application-testing/application-harness/spectacular-application-harness';\n// Feature testing API\n//   Configuration\nexport * from './lib/feature-testing/configuration/provide-spectacular-feature-testing';\nexport * from './lib/feature-testing/configuration/spectacular-feature-testing-features';\nexport * from './lib/feature-testing/configuration/with-initial-feature-navigation';\n//   Feature harness\nexport * from './lib/feature-testing/feature-harness/create-feature-harness';\nexport * from './lib/feature-testing/feature-harness/spectacular-feature-harness';\n//   Navigation\nexport * from './lib/feature-testing/navigation/spectacular-feature-location';\nexport * from './lib/feature-testing/navigation/spectacular-feature-router';\n// Pipe testing API\nexport * from './lib/pipe-testing/pipe-harness/create-pipe-harness';\nexport * from './lib/pipe-testing/pipe-harness/spectacular-pipe-harness';\n// Shared testing API\nexport * from './lib/shared/app-component/spectacular-app.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAGA;;AAEG;AACI,MAAM,iBAAiB,GAAG;AAEjC;;AAEG;MAOU,uBAAuB,CAAA;AASlC;;AAEG;IACH,kBAAkB,GAAA;AAChB,QAAA,IAAI,CAAC,IAAI,CAAC,YAAY,EAAE;AACtB,YAAA,MAAM,IAAI,KAAK,CACb,uFAAuF,CACxF;AACF,QAAA;AAED,QAAA,OAAO,IAAI,CAAC,YAAY,CAAC,SAA6B;IACxD;8GApBW,uBAAuB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAvB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,uBAAuB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,iBAAA,EAAA,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