Skip to content

Commit d64ff4c

Browse files
committed
feat: support ng-update migration
1 parent dcb0813 commit d64ff4c

File tree

4 files changed

+16
-109
lines changed

4 files changed

+16
-109
lines changed

angular.json

Lines changed: 10 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,8 @@
2020
"main": "apps/example-app/src/main.ts",
2121
"polyfills": "apps/example-app/src/polyfills.ts",
2222
"tsConfig": "apps/example-app/tsconfig.app.json",
23-
"assets": [
24-
"apps/example-app/src/favicon.ico",
25-
"apps/example-app/src/assets"
26-
],
27-
"styles": [
28-
"apps/example-app/src/styles.css"
29-
],
23+
"assets": ["apps/example-app/src/favicon.ico", "apps/example-app/src/assets"],
24+
"styles": ["apps/example-app/src/styles.css"],
3025
"scripts": [],
3126
"vendorChunk": true,
3227
"extractLicenses": false,
@@ -58,9 +53,7 @@
5853
"buildOptimizer": true
5954
}
6055
},
61-
"outputs": [
62-
"{options.outputPath}"
63-
]
56+
"outputs": ["{options.outputPath}"]
6457
},
6558
"serve": {
6659
"builder": "@angular-devkit/build-angular:dev-server",
@@ -97,9 +90,7 @@
9790
"jestConfig": "apps/example-app/jest.config.js",
9891
"setupFile": "apps/example-app/src/test-setup.ts"
9992
},
100-
"outputs": [
101-
"coverage/"
102-
]
93+
"outputs": ["coverage/"]
10394
}
10495
}
10596
},
@@ -144,6 +135,9 @@
144135
},
145136
{
146137
"command": "cpy ./README.md ./dist/@testing-library/angular"
138+
},
139+
{
140+
"command": "cpy schematics/**/*.json ../../dist/@testing-library/angular --cwd=./projects/testing-library --parents"
147141
}
148142
]
149143
}
@@ -154,9 +148,7 @@
154148
"jestConfig": "projects/testing-library/jest.config.js",
155149
"setupFile": "projects/testing-library/test-setup.ts"
156150
},
157-
"outputs": [
158-
"coverage/projects/testing-library"
159-
]
151+
"outputs": ["coverage/projects/testing-library"]
160152
}
161153
}
162154
},
@@ -208,11 +200,9 @@
208200
"jestConfig": "projects/jest-utils/jest.config.js",
209201
"setupFile": "projects/jest-utils/test-setup.ts"
210202
},
211-
"outputs": [
212-
"coverage/projects/jest-utils"
213-
]
203+
"outputs": ["coverage/projects/jest-utils"]
214204
}
215205
}
216206
}
217207
}
218-
}
208+
}

migrations.json

Lines changed: 0 additions & 89 deletions
This file was deleted.

projects/testing-library/package.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@
2121
"url": "https://github.com/testing-library/angular-testing-library/issues"
2222
},
2323
"homepage": "https://github.com/testing-library/angular-testing-library#readme",
24+
"ng-update": {
25+
"migrations": "./schematics/migrations/migration.json"
26+
},
2427
"peerDependencies": {
2528
"@angular/common": ">= 10.0.0",
2629
"@angular/platform-browser": ">= 10.0.0",
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"schematics": {}
3+
}

0 commit comments

Comments
 (0)