From 62877bdf2b0449d8c12a167c59d0c24c77467f37 Mon Sep 17 00:00:00 2001 From: Doug Parker Date: Mon, 14 Oct 2024 14:05:38 -0700 Subject: [PATCH] refactor(@angular-devkit/build-angular): remove Protractor builder and schematics BREAKING CHANGE: Protractor is no longer supported. Protractor was marked end-of-life in August 2023 (see https://protractortest.org/). Projects still relying on Protractor should consider migrating to another E2E testing framework, several support solid migration paths from Protractor. * https://angular.dev/tools/cli/end-to-end * https://blog.angular.dev/the-state-of-end-to-end-testing-with-angular-d175f751cb9c --- .../cli/lib/config/workspace-schema.json | 23 ------------------- .../build_angular/builders.json | 4 ++-- packages/schematics/angular/collection.json | 4 ++-- .../angular/utility/workspace-models.ts | 2 +- 4 files changed, 5 insertions(+), 28 deletions(-) diff --git a/packages/angular/cli/lib/config/workspace-schema.json b/packages/angular/cli/lib/config/workspace-schema.json index 650ae3ae18f2..dce8ecfec6fa 100644 --- a/packages/angular/cli/lib/config/workspace-schema.json +++ b/packages/angular/cli/lib/config/workspace-schema.json @@ -368,7 +368,6 @@ "@angular-devkit/build-angular:prerender", "@angular-devkit/build-angular:jest", "@angular-devkit/build-angular:web-test-runner", - "@angular-devkit/build-angular:protractor", "@angular-devkit/build-angular:server", "@angular-devkit/build-angular:ssr-dev-server" ] @@ -656,28 +655,6 @@ } } }, - { - "type": "object", - "additionalProperties": false, - "properties": { - "builder": { - "const": "@angular-devkit/build-angular:protractor" - }, - "defaultConfiguration": { - "type": "string", - "description": "A default named configuration to use when a target configuration is not provided." - }, - "options": { - "$ref": "../../../../angular_devkit/build_angular/src/builders/protractor/schema.json" - }, - "configurations": { - "type": "object", - "additionalProperties": { - "$ref": "../../../../angular_devkit/build_angular/src/builders/protractor/schema.json" - } - } - } - }, { "type": "object", "additionalProperties": false, diff --git a/packages/angular_devkit/build_angular/builders.json b/packages/angular_devkit/build_angular/builders.json index 5f76fa25d471..9141cdf94f2f 100644 --- a/packages/angular_devkit/build_angular/builders.json +++ b/packages/angular_devkit/build_angular/builders.json @@ -42,10 +42,10 @@ "schema": "./src/builders/web-test-runner/schema.json", "description": "Run unit tests with Web Test Runner." }, - "protractor": { + "private-protractor": { "implementation": "./src/builders/protractor", "schema": "./src/builders/protractor/schema.json", - "description": "Run protractor over a dev server." + "description": "PRIVATE API - Do not use." }, "server": { "implementation": "./src/builders/server", diff --git a/packages/schematics/angular/collection.json b/packages/schematics/angular/collection.json index f4def2da5a43..5f691819544f 100755 --- a/packages/schematics/angular/collection.json +++ b/packages/schematics/angular/collection.json @@ -23,10 +23,10 @@ "schema": "./application/schema.json", "description": "Create an Angular application." }, - "e2e": { + "private-e2e": { "factory": "./e2e", "schema": "./e2e/schema.json", - "description": "Create an Angular e2e application.", + "description": "PRIVATE API - Do not use.", "hidden": true }, "class": { diff --git a/packages/schematics/angular/utility/workspace-models.ts b/packages/schematics/angular/utility/workspace-models.ts index 49330e29e2bd..41c41345f736 100644 --- a/packages/schematics/angular/utility/workspace-models.ts +++ b/packages/schematics/angular/utility/workspace-models.ts @@ -30,7 +30,7 @@ export enum Builders { NgPackagr = '@angular-devkit/build-angular:ng-packagr', DevServer = '@angular-devkit/build-angular:dev-server', ExtractI18n = '@angular-devkit/build-angular:extract-i18n', - Protractor = '@angular-devkit/build-angular:protractor', + Protractor = '@angular-devkit/build-angular:private-protractor', BuildApplication = '@angular/build:application', }