diff --git a/goldens/public-api/angular_devkit/schematics/testing/index.md b/goldens/public-api/angular_devkit/schematics/testing/index.md index e64e6ae107..579b1ccdb6 100644 --- a/goldens/public-api/angular_devkit/schematics/testing/index.md +++ b/goldens/public-api/angular_devkit/schematics/testing/index.md @@ -24,12 +24,8 @@ export class SchematicTestRunner { registerCollection(collectionName: string, collectionPath: string): void; // (undocumented) runExternalSchematic(collectionName: string, schematicName: string, opts?: SchematicSchemaT, tree?: Tree_2): Promise; - // @deprecated (undocumented) - runExternalSchematicAsync(collectionName: string, schematicName: string, opts?: SchematicSchemaT, tree?: Tree_2): Observable; // (undocumented) runSchematic(schematicName: string, opts?: SchematicSchemaT, tree?: Tree_2): Promise; - // @deprecated (undocumented) - runSchematicAsync(schematicName: string, opts?: SchematicSchemaT, tree?: Tree_2): Observable; // (undocumented) get tasks(): TaskConfiguration[]; } diff --git a/packages/angular_devkit/schematics/testing/schematic-test-runner.ts b/packages/angular_devkit/schematics/testing/schematic-test-runner.ts index e4879d46a6..b9ae6cfd4b 100644 --- a/packages/angular_devkit/schematics/testing/schematic-test-runner.ts +++ b/packages/angular_devkit/schematics/testing/schematic-test-runner.ts @@ -7,7 +7,7 @@ */ import { logging, schema } from '@angular-devkit/core'; -import { Observable, from, lastValueFrom, of as observableOf } from 'rxjs'; +import { Observable, lastValueFrom, of as observableOf } from 'rxjs'; import { Collection, DelegateTree, @@ -48,7 +48,10 @@ export class SchematicTestRunner { private _collection: Collection<{}, {}>; private _logger: logging.Logger; - constructor(private _collectionName: string, collectionPath: string) { + constructor( + private _collectionName: string, + collectionPath: string, + ) { this._engineHost.registerCollection(_collectionName, collectionPath); this._logger = new logging.Logger('test'); @@ -91,17 +94,6 @@ export class SchematicTestRunner { return new UnitTestTree(newTree); } - /** - * @deprecated since version 15.1. Use `runSchematic` instead. - */ - runSchematicAsync( - schematicName: string, - opts?: SchematicSchemaT, - tree?: Tree, - ): Observable { - return from(this.runSchematic(schematicName, opts, tree)); - } - async runExternalSchematic( collectionName: string, schematicName: string, @@ -118,18 +110,6 @@ export class SchematicTestRunner { return new UnitTestTree(newTree); } - /** - * @deprecated since version 15.1. Use `runExternalSchematic` instead. - */ - runExternalSchematicAsync( - collectionName: string, - schematicName: string, - opts?: SchematicSchemaT, - tree?: Tree, - ): Observable { - return from(this.runExternalSchematic(collectionName, schematicName, opts, tree)); - } - callRule(rule: Rule, tree: Tree, parentContext?: Partial): Observable { const context = this._engine.createContext({} as Schematic<{}, {}>, parentContext);