mirror of https://github.com/grpc/grpc-node.git
build: update build files
This commit is contained in:
parent
41305f595c
commit
a35fad015d
|
|
@ -55,16 +55,15 @@ function loadGulpTasksWithPrefix(path: string, prefix: string) {
|
||||||
['./packages/grpc-native-core/gulpfile', 'native.core'],
|
['./packages/grpc-native-core/gulpfile', 'native.core'],
|
||||||
['./packages/grpc-surface/gulpfile', 'surface'],
|
['./packages/grpc-surface/gulpfile', 'surface'],
|
||||||
['./packages/grpc-protobufjs/gulpfile', 'protobuf'],
|
['./packages/grpc-protobufjs/gulpfile', 'protobuf'],
|
||||||
['./test/gulpfile', 'internal.test'],
|
|
||||||
].forEach((args) => loadGulpTasksWithPrefix(args[0], args[1]));
|
].forEach((args) => loadGulpTasksWithPrefix(args[0], args[1]));
|
||||||
|
|
||||||
const root = __dirname;
|
const root = __dirname;
|
||||||
|
|
||||||
gulp.task('install.all', 'Install dependencies for all subdirectory packages',
|
gulp.task('install.all', 'Install dependencies for all subdirectory packages',
|
||||||
['js.install', 'js.core.install', 'native.core.install', 'surface.install', 'health-check.install', 'protobuf.install', 'internal.test.install']);
|
['js.install', 'js.core.install', 'native.core.install', 'surface.install', 'health-check.install', 'protobuf.install']);
|
||||||
|
|
||||||
gulp.task('install.all.windows', 'Install dependencies for all subdirectory packages for MS Windows',
|
gulp.task('install.all.windows', 'Install dependencies for all subdirectory packages for MS Windows',
|
||||||
['js.core.install', 'native.core.install.windows', 'surface.install', 'health-check.install', 'protobuf.install', 'internal.test.install']);
|
['js.core.install', 'native.core.install.windows', 'surface.install', 'health-check.install', 'protobuf.install']);
|
||||||
|
|
||||||
gulp.task('lint', 'Emit linting errors in source and test files',
|
gulp.task('lint', 'Emit linting errors in source and test files',
|
||||||
['js.core.lint', 'native.core.lint']);
|
['js.core.lint', 'native.core.lint']);
|
||||||
|
|
@ -96,10 +95,10 @@ gulp.task('clean', 'Delete generated files', ['js.core.clean', 'native.core.clea
|
||||||
|
|
||||||
gulp.task('clean.all', 'Delete all files created by tasks',
|
gulp.task('clean.all', 'Delete all files created by tasks',
|
||||||
['js.core.clean.all', 'native.core.clean.all', 'health-check.clean.all',
|
['js.core.clean.all', 'native.core.clean.all', 'health-check.clean.all',
|
||||||
'internal.test.clean.all', 'js.clean.all', 'native.clean.all', 'protobuf.clean.all']);
|
'js.clean.all', 'native.clean.all', 'protobuf.clean.all']);
|
||||||
|
|
||||||
gulp.task('native.test.only', 'Run tests of native code without rebuilding anything',
|
gulp.task('native.test.only', 'Run tests of native code without rebuilding anything',
|
||||||
['native.core.test', 'internal.test.test', 'health-check.test']);
|
['native.core.test', 'health-check.test']);
|
||||||
|
|
||||||
gulp.task('native.test', 'Run tests of native code', (callback) => {
|
gulp.task('native.test', 'Run tests of native code', (callback) => {
|
||||||
runSequence('build', 'native.test.only', callback);
|
runSequence('build', 'native.test.only', callback);
|
||||||
|
|
|
||||||
|
|
@ -34,8 +34,16 @@
|
||||||
"protobufjs": "^5.0.0"
|
"protobufjs": "^5.0.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"async": "^2.0.1",
|
||||||
|
"body-parser": "^1.15.2",
|
||||||
"electron-mocha": "^3.1.1",
|
"electron-mocha": "^3.1.1",
|
||||||
"istanbul": "^0.4.4"
|
"express": "^4.14.0",
|
||||||
|
"google-auth-library": "^0.9.2",
|
||||||
|
"google-protobuf": "^3.0.0",
|
||||||
|
"istanbul": "^0.4.4",
|
||||||
|
"lodash": "^4.17.4",
|
||||||
|
"minimist": "^1.1.0",
|
||||||
|
"poisson-process": "^0.2.1"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=4"
|
"node": ">=4"
|
||||||
|
|
|
||||||
|
|
@ -1,40 +0,0 @@
|
||||||
/*
|
|
||||||
* Copyright 2017 gRPC authors.
|
|
||||||
*
|
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
* you may not use this file except in compliance with the License.
|
|
||||||
* You may obtain a copy of the License at
|
|
||||||
*
|
|
||||||
* http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
*
|
|
||||||
* Unless required by applicable law or agreed to in writing, software
|
|
||||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
* See the License for the specific language governing permissions and
|
|
||||||
* limitations under the License.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
|
|
||||||
const _gulp = require('gulp');
|
|
||||||
const help = require('gulp-help');
|
|
||||||
const mocha = require('gulp-mocha');
|
|
||||||
const execa = require('execa');
|
|
||||||
const path = require('path');
|
|
||||||
const del = require('del');
|
|
||||||
const linkSync = require('../util').linkSync;
|
|
||||||
|
|
||||||
// gulp-help monkeypatches tasks to have an additional description parameter
|
|
||||||
const gulp = help(_gulp);
|
|
||||||
|
|
||||||
const testDir = __dirname;
|
|
||||||
const apiTestDir = path.resolve(testDir, 'api');
|
|
||||||
|
|
||||||
gulp.task('install', 'Install test dependencies', () => {
|
|
||||||
return execa('npm', ['install'], {cwd: testDir, stdio: 'inherit'});
|
|
||||||
});
|
|
||||||
|
|
||||||
gulp.task('clean.all', 'Delete all files created by tasks', () => {});
|
|
||||||
|
|
||||||
gulp.task('test', 'Run API-level tests', () => {
|
|
||||||
return gulp.src(`${apiTestDir}/*.js`).pipe(mocha({reporter: 'mocha-jenkins-reporter'}));
|
|
||||||
});
|
|
||||||
|
|
@ -1,26 +0,0 @@
|
||||||
{
|
|
||||||
"name": "grpc-node-test",
|
|
||||||
"version": "0.1.0",
|
|
||||||
"description": "Dummy package for the grpc-node repository tests",
|
|
||||||
"private": true,
|
|
||||||
"keywords": [],
|
|
||||||
"author": {
|
|
||||||
"name": "Google Inc."
|
|
||||||
},
|
|
||||||
"license": "Apache-2.0",
|
|
||||||
"contributors": [
|
|
||||||
{
|
|
||||||
"name": "Google Inc."
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"dependencies": {
|
|
||||||
"async": "^2.0.1",
|
|
||||||
"body-parser": "^1.15.2",
|
|
||||||
"express": "^4.14.0",
|
|
||||||
"google-auth-library": "^0.9.2",
|
|
||||||
"google-protobuf": "^3.0.0",
|
|
||||||
"lodash": "^4.17.4",
|
|
||||||
"minimist": "^1.1.0",
|
|
||||||
"poisson-process": "^0.2.1"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Loading…
Reference in New Issue