diff --git a/integration/ngcc/package.json b/integration/ngcc/package.json new file mode 100644 index 0000000000..156054a557 --- /dev/null +++ b/integration/ngcc/package.json @@ -0,0 +1,31 @@ +{ + "name": "angular-integration", + "version": "0.0.0", + "license": "MIT", + "dependencies": { + "@angular/animations": "file:../../dist/packages-dist/animations", + "@angular/common": "file:../../dist/packages-dist/common", + "@angular/compiler": "file:../../dist/packages-dist/compiler", + "@angular/compiler-cli": "file:../../dist/packages-dist/compiler-cli", + "@angular/core": "file:../../dist/packages-dist/core", + "@angular/forms": "file:../../dist/packages-dist/forms", + "@angular/http": "file:../../dist/packages-dist/http", + "@angular/platform-browser": "file:../../dist/packages-dist/platform-browser", + "@angular/platform-browser-dynamic": "file:../../dist/packages-dist/platform-browser-dynamic", + "@angular/platform-server": "file:../../dist/packages-dist/platform-server", + "@angular/router": "file:../../dist/packages-dist/router", + "@types/node": "^9.4.0", + "rxjs": "file:../../node_modules/rxjs", + "typescript": "file:../../node_modules/typescript", + "zone.js": "file:../../node_modules/zone.js" + }, + "devDependencies": { + "@types/jasmine": "2.5.41", + "concurrently": "3.4.0", + "lite-server": "2.2.2", + "protractor": "file:../../node_modules/protractor" + }, + "scripts": { + "test": "./test.sh" + } +} diff --git a/integration/ngcc/src/main.ts b/integration/ngcc/src/main.ts new file mode 100644 index 0000000000..9ec0192957 --- /dev/null +++ b/integration/ngcc/src/main.ts @@ -0,0 +1,20 @@ +import {Component, NgModule, ɵrenderComponent as renderComponent} from '@angular/core'; +import {CommonModule} from '@angular/common'; +@Component({ + selector: 'hello-world', + template: ` + +

Hello World

+ `, +}) +class HelloWorld { + visible = false; +} + +@NgModule({ + declarations: [HelloWorld], + imports: [CommonModule], +}) +class Module {} + +renderComponent(HelloWorld); diff --git a/integration/ngcc/test.sh b/integration/ngcc/test.sh new file mode 100755 index 0000000000..8d98c5ebc9 --- /dev/null +++ b/integration/ngcc/test.sh @@ -0,0 +1,10 @@ +#!/bin/bash + +set -x + +PATH=$PATH:$(npm bin) + +ivy-ngcc node_modules/@angular/common esm2015 +cp -r node_modules_ngtsc/* node_modules/ +ngc -p tsconfig-app.json + diff --git a/integration/ngcc/tsconfig-app.json b/integration/ngcc/tsconfig-app.json new file mode 100644 index 0000000000..ab1b05c33f --- /dev/null +++ b/integration/ngcc/tsconfig-app.json @@ -0,0 +1,19 @@ +{ + "compilerOptions": { + "target": "es5", + "module": "commonjs", + "moduleResolution": "node", + "lib": ["es2015", "dom"], + "experimentalDecorators": true, + "emitDecoratorMetadata": true, + "outDir": "dist", + "types": ["node"], + "rootDir": "." + }, + "files": [ + "src/main.ts" + ], + "angularCompilerOptions": { + "enableIvy": "ngtsc" + } +} \ No newline at end of file