From a7e9bc97f6a19a2b47b962bd021cb91346a44baa Mon Sep 17 00:00:00 2001 From: Alex Eagle Date: Mon, 8 Feb 2016 13:23:12 -0800 Subject: [PATCH] ci(typescript): add typescript_next build Install typescript@next before build.js and test.typings. Restore the regular version before travis caches node_modules/. Fixes #6368 --- .travis.yml | 7 +++++++ .../playground/src/web_workers/images/services/bitmap.ts | 2 +- scripts/ci/build_and_test.sh | 5 +++++ scripts/ci/build_dart_ddc.sh | 2 +- 4 files changed, 14 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index d06aa43fb2..d128e6f8ea 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,6 +12,10 @@ cache: - node_modules - $HOME/.pub-cache +before_cache: + # Undo the pollution of the typescript_next build + - npm install typescript + env: global: - KARMA_BROWSERS=DartiumWithWebPlatform @@ -46,6 +50,7 @@ env: - MODE=js DART_CHANNEL=dev DART_VERSION=$DART_DEV_VERSION - MODE=router DART_CHANNEL=dev DART_VERSION=$DART_DEV_VERSION - MODE=build_only DART_CHANNEL=stable DART_VERSION=$DART_STABLE_VERSION + - MODE=typescript_next DART_CHANNEL=stable DART_VERSION=$DART_STABLE_VERSION - MODE=lint DART_CHANNEL=dev DART_VERSION=$DART_DEV_VERSION - MODE=payload DART_CHANNEL=stable DART_VERSION=$DART_STABLE_VERSION @@ -55,6 +60,8 @@ matrix: - env: "MODE=browserstack_optional DART_CHANNEL=dev DART_VERSION=$DART_DEV_VERSION" # TODO(alxhub): remove when dartdoc #1039 is in dev channel - env: "MODE=dart DART_CHANNEL=dev DART_VERSION=$DART_DEV_VERSION" + # Tracked in https://github.com/angular/angular/issues/7050 + - env: "MODE=typescript_next DART_CHANNEL=stable DART_VERSION=$DART_STABLE_VERSION" addons: firefox: "38.0" diff --git a/modules/playground/src/web_workers/images/services/bitmap.ts b/modules/playground/src/web_workers/images/services/bitmap.ts index 9bb68fb369..0b6004240b 100644 --- a/modules/playground/src/web_workers/images/services/bitmap.ts +++ b/modules/playground/src/web_workers/images/services/bitmap.ts @@ -63,7 +63,7 @@ export class BitmapService { return imageData; } - private _swap(data: any[], index1: number, index2: number) { + private _swap(data: Uint8Array | number[], index1: number, index2: number) { var temp = data[index1]; data[index1] = data[index2]; data[index2] = temp; diff --git a/scripts/ci/build_and_test.sh b/scripts/ci/build_and_test.sh index 233abb0647..2da7b636a9 100755 --- a/scripts/ci/build_and_test.sh +++ b/scripts/ci/build_and_test.sh @@ -19,6 +19,11 @@ elif [ "$MODE" = "lint" ]; then elif [ "$MODE" = "build_only" ]; then ${SCRIPT_DIR}/build_js.sh ${SCRIPT_DIR}/build_dart.sh +elif [ "$MODE" = "typescript_next" ]; then + # Ignore complaints about unsatisfied peer deps + npm install typescript@next || true + ${SCRIPT_DIR}/build_js.sh + ./node_modules/.bin/gulp test.typings elif [ "$MODE" = "payload" ]; then source ${SCRIPT_DIR}/env_dart.sh ./node_modules/.bin/gulp test.payload.dart/ci diff --git a/scripts/ci/build_dart_ddc.sh b/scripts/ci/build_dart_ddc.sh index 4ecd04331a..dff10365b9 100755 --- a/scripts/ci/build_dart_ddc.sh +++ b/scripts/ci/build_dart_ddc.sh @@ -12,7 +12,7 @@ cd $SCRIPT_DIR/../.. # Variables DDC_TOTAL_WARNING_CAP="1000" -DDC_TOTAL_ERROR_CAP="6" +DDC_TOTAL_ERROR_CAP="11" DDC_DIR=`pwd`/tmp/dev_compiler DDC_VERSION="0.1.14"