mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-18 11:17:19 +08:00
fix(): update for e2e to use ionic core components.
This commit is contained in:
@ -23,7 +23,8 @@
|
|||||||
"test": "gulp validate",
|
"test": "gulp validate",
|
||||||
"test:generators": "jasmine-node ./tooling/spec",
|
"test:generators": "jasmine-node ./tooling/spec",
|
||||||
"link": "gulp release.prepareReleasePackage && cd dist/ionic-angular && npm link",
|
"link": "gulp release.prepareReleasePackage && cd dist/ionic-angular && npm link",
|
||||||
"link.stencil": "npm link @stencil/core"
|
"link.stencil": "npm link @stencil/core",
|
||||||
|
"build.stencil": "stencil build"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@angular/common": "4.1.3",
|
"@angular/common": "4.1.3",
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
import { dirname, join } from 'path';
|
import { dirname, join } from 'path';
|
||||||
import { readFileSync } from 'fs';
|
import { readFileSync } from 'fs';
|
||||||
|
import { spawnSync } from 'child_process';
|
||||||
|
|
||||||
import { task } from 'gulp';
|
import { task } from 'gulp';
|
||||||
|
|
||||||
@ -24,13 +25,15 @@ function serveTest(folderInfo: any) {
|
|||||||
const testOrDemoName = join(folderInfo.componentName, folderInfo.componentTest);
|
const testOrDemoName = join(folderInfo.componentName, folderInfo.componentTest);
|
||||||
const ionicAngularDir = join(PROJECT_ROOT, 'src');
|
const ionicAngularDir = join(PROJECT_ROOT, 'src');
|
||||||
const coreCompilerFilePath = join(PROJECT_ROOT, '..', 'ionic-core', 'dist', 'compiler');
|
const coreCompilerFilePath = join(PROJECT_ROOT, '..', 'ionic-core', 'dist', 'compiler');
|
||||||
const coreDir = join(PROJECT_ROOT, '..', 'ionic-core', 'dist', 'compiled-ionic-angular');
|
const coreDir = join(PROJECT_ROOT, 'dist', 'core');
|
||||||
const srcTestRoot = join(PROJECT_ROOT, 'src', 'components', folderInfo.componentName, 'test', folderInfo.componentTest);
|
const srcTestRoot = join(PROJECT_ROOT, 'src', 'components', folderInfo.componentName, 'test', folderInfo.componentTest);
|
||||||
const distTestRoot = join(PROJECT_ROOT, 'dist', 'e2e', 'components', folderInfo.componentName, 'test', folderInfo.componentTest);
|
const distTestRoot = join(PROJECT_ROOT, 'dist', 'e2e', 'components', folderInfo.componentName, 'test', folderInfo.componentTest);
|
||||||
const includeGlob = [ join(ionicAngularDir, '**', '*.ts')];
|
const includeGlob = [ join(ionicAngularDir, '**', '*.ts')];
|
||||||
const pathToWriteFile = join(distTestRoot, 'tsconfig.json');
|
const pathToWriteFile = join(distTestRoot, 'tsconfig.json');
|
||||||
const pathToReadFile = join(PROJECT_ROOT, 'tsconfig.json');
|
const pathToReadFile = join(PROJECT_ROOT, 'tsconfig.json');
|
||||||
|
|
||||||
|
spawnSync('npm', ['run', 'build.stencil']);
|
||||||
|
|
||||||
createTempTsConfig(includeGlob, ES_2015, ES_2015, pathToReadFile, pathToWriteFile, { removeComments: true});
|
createTempTsConfig(includeGlob, ES_2015, ES_2015, pathToReadFile, pathToWriteFile, { removeComments: true});
|
||||||
|
|
||||||
const sassConfigPath = join('scripts', 'e2e', 'sass.config.js');
|
const sassConfigPath = join('scripts', 'e2e', 'sass.config.js');
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
exports.config = {
|
exports.config = {
|
||||||
dest: 'dist',
|
dest: 'dist/core',
|
||||||
collections: [
|
collections: [
|
||||||
'@ionic/core'
|
'@ionic/core'
|
||||||
]
|
]
|
||||||
|
Reference in New Issue
Block a user