Commit Graph

237 Commits

Author SHA1 Message Date
Julie Ralph 8490921fb3 feat(tests): manage asynchronous tests using zones
Instead of using injectAsync and returning a promise, use the `async` function
to wrap tests. This will run the test inside a zone which does not complete
the test until all asynchronous tasks have been completed.

`async` may be used with the `inject` function, or separately.

BREAKING CHANGE:

`injectAsync` is now deprecated. Instead, use the `async` function
to wrap any asynchronous tests.

Before:
```
it('should wait for returned promises', injectAsync([FancyService], (service) => {
  return service.getAsyncValue().then((value) => { expect(value).toEqual('async value'); });
}));

it('should wait for returned promises', injectAsync([], () => {
  return somePromise.then(() => { expect(true).toEqual(true); });
}));
```

After:
```
it('should wait for returned promises', async(inject([FancyService], (service) => {
  service.getAsyncValue().then((value) => { expect(value).toEqual('async value'); });
})));

// Note that if there is no injection, we no longer need `inject` OR `injectAsync`.
it('should wait for returned promises', async(() => {
  somePromise.then() => { expect(true).toEqual(true); });
}));
```

Closes #7735
2016-04-18 15:59:07 -07:00
Alex Eagle 3412aba46e feat(typescript): update to 1.9 nightly.
To workaround https://github.com/Microsoft/TypeScript/issues/7573
we must remove the readonly keyword from generated .d.ts files.
This solution will not scale, but will probably buy enough time to require our users move to a 2.0 beta.

Closes #8003
2016-04-13 18:54:58 +00:00
Alex Rickabaugh 60727c4d2b revert(format): Revert "chore(format): update to latest formatter"
This reverts commit 03627aa84d.
2016-04-12 09:41:01 -07:00
Alex Eagle 03627aa84d chore(format): update to latest formatter
Closes #7958
2016-04-11 22:15:23 +00:00
Felix Itzenplitz 27cf897239 chore: upgrade zone.js to v0.6.10
Closes #7818
Closes #7721

Closes #7888
2016-04-11 21:03:59 +00:00
Alex Eagle 9a1959f77a build(tslint): re-enable linter and fix violations
fixes #7798

Closes #7800
2016-04-07 23:11:02 +00:00
Misko Hevery d940387beb chore: upgrade zone.js to v0.6.6
Closes #7730
Closes #7737
2016-03-23 20:48:23 +00:00
Misko Hevery bf911fc992 chore: upgrade zone.js@0.6.5
Closes #7700
2016-03-22 08:21:10 -07:00
Igor Minar b0f585ab08 build(npm): bump Angular version in our shrinkwrap files 2016-03-22 01:53:35 +00:00
Igor Minar 8b67b07580 fix(package.json): remove es6-promise from the peerDependency list
As of zone.js@0.6* we no longer require an es6-promise polyfill. The polyfill is only needed on browsers that don't
have native Promise support.
2016-03-22 01:53:35 +00:00
Misko Hevery a5e6eaaebc chore: upgrade es6-shim to v0.35.0
Closes #7653
2016-03-18 13:16:15 -07:00
Misko Hevery 310620fd12 chore: upgrade to new Zone.js API v0.6.2
BREAKING CHANGE

Removed deprecated API from NgZone
- `NgZone.overrideOnTurnStart`
- `NgZone.overrideOnTurnDone`
- `NgZone.overrideOnEventDone`
- `NgZone.overrideOnErrorHandler`

Rename NgZone API
- `NgZone.onTurnStart` => `NgZone.onUnstable`
- `NgZone.onTurnDone` => `NgZone.onMicrotaskEmpty`
- `NgZone.onEventDone` => `NgZone.onStable`

Closes #7345
2016-03-16 18:05:09 +00:00
Misko Hevery 14f0e9ada8 chore: fix DDC errors / warnings
Closes #7195
2016-03-08 22:17:32 +00:00
Jeff Cross ce72ccf9e8 build(npm): bump zone.js version to 0.15.5 2016-02-17 16:28:50 -08:00
Jeff Cross 46d9c87ddc build(package): bump rxjs to 5.0.0-beta.2
Closes #7001
2016-02-17 16:28:50 -08:00
Alex Eagle ae275fa4e4 chore(ts2dart): update ts2dart to 0.7.24 2016-02-12 20:45:35 -08:00
Alex Eagle f161b5cc28 chore(zone.js): update to 0.5.14 2016-02-11 14:39:41 -08:00
Alex Eagle 117d57e121 Revert "chore(zone.js) : update to 0.5.14"
This reverts commit 3dcce706fd.
2016-02-11 14:38:06 -08:00
Brian Ford 3dcce706fd chore(zone.js) : update to 0.5.14 2016-02-11 14:15:59 -08:00
Alex Eagle 3d715a2f7b fix(typings): publish es6 typings rather than postinstall.
Despite local testing, multiple users failed to run the postinstall to install typings.
Instead, we can distribute the typings we installed locally.

This is an alternative to #7003.
This also reverts rxjs to beta.1 since we have errors using beta.2, being addressed
in #7001.

Fixes #7000
2016-02-11 11:04:42 -08:00
Peter Bacon Darwin d86be245b8 fix(angular1-router): add support for using the component helper
In Angular 1.5 there is a new helper method for creating component directives.
See https://docs.angularjs.org/guide/component for more information about components.

These kind of directives only match the `E` element form and the previously component
router only created HTML that matched directives that matched the `A` attribute form.

This commit changes the `<ng-outlet>` directive so that it generates custom HTML
elements rather divs with custom attributes to trigger the relevant component to
appear in the DOM.

Going forward, Angular 1.5 users are encouraged to create their router components
using the following style:

```
myModule.componnet('component-name', {
  // component definition object
});
```

Closes angular/angular.js#13860
Closes #6076
Closes #5278

BREAKING CHANGE:

The component router now creates custom element HTML rather than custom attribute
HTML, in order to create a new component. So rather than

```html
<div custom-component></div>
```

it now creates

```html
<custom-component></custom-component>
```

If you defined you router components using the `directive()` helper and
specified the `restrict` properties such that element matching was not allowed,
e.g. `restrict: 'A'` then these components will no longer be instantiated
by the component router and the outlet will be empty.

The fix is to include `E` in the `restrict` property.

`restrict: 'EA'`

Note that this does not affect directives that did not specify the `restrict`
property as the default for this property is already `EA`.
2016-02-08 16:18:13 -08:00
Igor Minar b0f7d59e64 revert: chore: update the version of ts2dart
This reverts commit 22929a1671.

This commits makes our build red without the other commit that was already reverted.

More info at: https://github.com/angular/angular/pull/6825#issuecomment-181592303
2016-02-08 14:13:00 -08:00
vsavkin 22929a1671 chore: update the version of ts2dart
Closes #6804
2016-02-05 21:56:33 +00:00
Alex Eagle 1435763383 chore(deps): update ts2dart and zone.js 2016-02-04 22:42:40 +00:00
Victor Berchet 8a645d5e44 chore(zone.js): update to 0.5.11
Closes #6751
2016-02-01 21:53:42 +00:00
vsavkin 68a799af2e tools: implement public api spec
Closes #6309
2016-01-27 21:19:05 +00:00
Igor Minar 31b81a7439 build(npm): update to karma-browserstack-launcher@0.1.9 2016-01-22 03:25:34 +00:00
Igor Minar f7b1973358 build(npm): bump Angular's version number in shrinkwrap files to 2.0.0-beta.1 2016-01-22 03:25:34 +00:00
Igor Minar 32f01da49a build(npm): update to karma@0.13.17
Mark says that karma-runner/karma#1768 is resolved in 0.13.17
2016-01-22 03:25:34 +00:00
Igor Minar 59684c97b0 build(npm): update to minimatch@3.0.0 2016-01-22 03:25:34 +00:00
Igor Minar a32a0a3a97 build(npm): update to semver@5.1.0 2016-01-22 03:25:33 +00:00
Igor Minar 8e6cf7fca8 build(npm): update to yargs@3.31.0 2016-01-22 03:25:33 +00:00
Igor Minar fdbe8741c9 build(npm): update to proxy-middleware@0.15.0 2016-01-22 03:25:33 +00:00
Igor Minar 775fb2c340 build(npm): remove googleapis
it was previously used by benchpress (see d02c0accbb) but that's no longer the case.

I also removed a bunch of extranous dependencies that should never have been part of node_modules (npm bug?)
2016-01-22 03:25:33 +00:00
Igor Minar b60f594798 build(npm): update to gulp-connect@2.3.1 2016-01-22 03:25:33 +00:00
Igor Minar cc49790bdb build(npm): update gulp-connect's dependencies 2016-01-22 03:25:33 +00:00
Igor Minar f7985dbdb7 build(npm): update to lodash@3.10.1 2016-01-22 03:25:33 +00:00
Igor Minar 0bdcb5c1e0 build(npm): remove `del` devDependency - use `fs-extra` instead 2016-01-22 03:25:33 +00:00
Igor Minar 625474c4e2 build(npm): update to mock-fs@3.6.0 2016-01-22 03:25:33 +00:00
Igor Minar 1cd2a6328a build(npm): update to fs-extra@0.26.3 2016-01-22 03:25:33 +00:00
Igor Minar d6bafe4fe3 build(npm): update to minimist@1.2.0 2016-01-22 03:25:33 +00:00
Igor Minar 6a2ef15355 build(npm): update to jasmine@2.4.1 2016-01-22 03:25:33 +00:00
Igor Minar a8ca560503 build(npm): upgrade to broccoli@0.16.9 2016-01-22 03:25:33 +00:00
Igor Minar ad361808ec build(npm): upgrade to broccoli-funnel@1.0.1 2016-01-22 03:25:33 +00:00
Igor Minar c47639f2b1 build(npm): upgrade to protractor@3.0.0 2016-01-22 03:25:33 +00:00
Igor Minar ba90a85f7b build(npm): downgrade to karma@0.13.15 due to RangeError bug
Ref https://github.com/karma-runner/karma/issues/1768
2016-01-22 03:25:33 +00:00
Igor Minar d3b569557f build(npm): upgrade to karma-sauce-launcher@0.3.0 2016-01-22 03:25:33 +00:00
Igor Minar c9090ffa31 build(npm): revert clang-format upgrade
there are too many reformatting changes require that would add noise to the upgrade commit
2016-01-22 03:25:33 +00:00
Igor Minar 341bf39d23 build(npm): update all npm dependencies + reshrinkwrap 2016-01-22 03:25:32 +00:00
Brian Ford 6cfc6f5bb2 build(npm): upgrade to npm v3
Closes #3193
2016-01-22 03:25:32 +00:00
Vikram Subramanian 95248f46a1 build(npm): update to ts2dart@0.7.19
Closes #6254
2016-01-09 01:44:01 +00:00
Jeff Cross 321ed7d099 chore(package): update rxjs to beta.0 2015-12-14 22:08:16 -08:00
Victor Berchet 0f8e40bb42 chore(zone.js) : update to 0.5.10
Closes #5845
2015-12-14 21:23:18 +00:00
vsavkin 4e5cd1e558 chore: update ts2dart to 0.7.18
Closes #5853
2015-12-12 19:28:13 +00:00
Igor Minar 01ba94ba56 build(npm): update to ts2dart@0.7.17
resolves regression in 0.7.16

Closes #5758
2015-12-10 01:32:45 +00:00
Igor Minar 51cb7586e0 build(npm): update to typescript@1.7.3 + fix broccoli-typescript + fix src 2015-12-10 01:32:44 +00:00
Igor Minar 796eee1e6f build(npm): update to gulp-typescript@2.10.0 2015-12-10 01:32:44 +00:00
Igor Minar c39828f0f2 build(npm): bump ts2dart to 0.7.16 2015-12-10 01:32:44 +00:00
Jeff Cross 4432cf5438 chore(package): update rxjs dependency to alpha.14
Closes #5722

Closes #5723
2015-12-08 18:54:43 -08:00
Igor Minar 11f98c58b3 build(npm): dedupe es6-promise dependency 2015-12-08 11:52:25 -08:00
Igor Minar c1e3ea9f7f build(npm): add es6-promise as a dependency
This is actually an inherited dependency that comes from zone.js.

See related issue: https://github.com/angular/zone.js/issues/212

It would be better to make this one an optionalPeerDependency but npm
currently doesn't support making peerDependencies optional.
See: https://github.com/npm/npm/issues/3066
2015-12-08 11:52:25 -08:00
Jeff Cross c39f4c3b38 refactor(Observable): implement toPromise and fromPromise without side effects
BREAKING CHANGE:

toPromise is no longer an instance method of the `Observable` returned
by Angular, and fromPromise is no longer available as a static method.

The easiest way to account for this change in applications is to import
the auto-patching modules from rxjs, which will automatically add these
operators back to the Observable prototype.

```
import 'rxjs/add/operator/toPromise';
import 'rxjs/add/observable/fromPromise';
```

Closes #5542
Closes #5626
2015-12-08 18:31:02 +00:00
Rob Wormald 4b1618cb03 fix(package): relock RxJS to alpha.11
fixes #5643

Closes #5644
2015-12-07 15:15:22 -08:00
Rob Wormald 5514dc19d9 refactor(facade): use rxjs package
move to new RxJS distribution.

BREAKING CHANGE:

RxJS imports now are via `rxjs` instead of `@reactivex/rxjs`
Individual operators can be imported `import 'rxjs/operators/map'`
2015-12-02 16:02:34 -08:00
Rob Wormald a16ac84840 refactor(async): use ultralight Observable
Closes #5283
2015-12-02 16:02:34 -08:00
Pawel Kozlowski 65bdf42903 chore(bundles): add source maps to umd dev bundles
Source maps are in-lined to follow the same conventions as
for non-bundled files.

Closes #5511
2015-11-30 20:17:13 +00:00
Pawel Kozlowski fa725b4512 feat(bundles): publish UMD bundles
Closes #5223
2015-11-25 13:16:01 -08:00
vsavkin 87d56acdaa fix(build): fix source maps
Closes #5444
2015-11-24 19:33:27 +00:00
Igor Minar 41dfaf393b build(analytics): track bundle size
This will send bundle sizes (before and after gzip) to Google Analytics so that we can
track bundle size over time for every bundle we produce.

Closes #5294
2015-11-16 21:42:50 +00:00
Marc Laval 63639895ad chore(package): update karma-browserstack-launcher to 0.1.7
Closes #5276
2015-11-13 22:20:50 +00:00
vsavkin b0009f03d5 chore(ts2dart): update ts2dart to 0.7.14
Closes #5167
2015-11-07 01:36:06 +00:00
Pawel Kozlowski c6ad269f43 chore(build): remove es5build.js
Fixes #5030

Closes #5144
2015-11-06 18:22:57 +00:00
Marc Laval c5693f07dc chore(browserstack): use patched karma launcher
closes #5142
2015-11-06 11:11:10 +01:00
Igor Minar b354b79b50 build(npm): cleanup + update npm dependencies + reshrinkwrap
In the previous commit I removed unused dependencies from package.json, but in order for the change to take
effect I needed to update npm shrinkwrap as well. That got complicated because of how npm dedupes packages.

Long story short, to clean up the mess I did the following:
- deleted npm-shrinkwrap.json and npm-shrinkwrap.clean.json
- ran: npm install
- ran: npm shrinkwrap --dev && ./tools/npm/clean-npm-shrinkwrap

This means that our npm-shrinkwrap now correctly reflects the constraints in package.json, but it also
means that some packages got updated (within the version constrain specified in package.json).

Some dependencies were intentionally not updated. e.g. mudge due to #5022
2015-11-05 21:02:42 +00:00
Marc Laval 84fe0c9d3e build(browserstack): add npm dependencies 2015-11-01 23:21:15 +01:00
Rob Wormald 0378e55fab chore(package): update RxJS version 2015-10-29 23:06:16 +00:00
Rob Wormald ca3986f31d refactor(async): refactor EventEmitter
Refactor EventEmitter and Async Facade to match ES7 Observable semantics, properly use RxJS typedefs, make EventEmitter inherit from RxJS Subject. Closes #4149.

BREAKING CHANGE:
- consumers of EventEmitter no longer need to call .toRx()
- EventEmitter is now generic and requires a type - e.g. `EventEmitter<string>`
- EventEmitter and Observable now use the `.subscribe(generatorOrNext, error, complete)` method instead of `.observer(generator)`
- ObservableWrapper uses `callNext/callError/callComplete` instead of `callNext/callThrow/callReturn`
2015-10-29 23:06:16 +00:00
Tobias Bosch 993b3d62de refactor(compiler): don’t rely on external css parser
We used to use different external css parsers,
depending on the `DomAdapter`. This lead to
inconsistent behavior and environment specific errors.

Closes #5006
Closes #4993
2015-10-29 15:09:39 -07:00
Alex Eagle 5f2eb3e078 chore(dgeni): clean up legacy typings bundle creation
Fixes #4967

Closes #4991
2015-10-29 21:19:59 +00:00
Tobias Bosch bc10dc3ed0 fix(benchmarks): update react and polymer benchmarks and get tree update numbers for all of the benchmarks as well.
Closes #4709
2015-10-28 13:17:01 -07:00
Alex Eagle c90e1920f5 chore(tslint): disallow variable names that look like keywords.
We've had issues such as the one I documented: https://github.com/Microsoft/TypeScript/issues/5187
This tslint check prevents this happening again.
This change also updates to the newest tslint which gets typings from npm.

Closes #4970
2015-10-28 18:31:21 +00:00
Martin Probst 4a1b873fad feat: upgrade clang-format to 1.0.32. 2015-10-28 08:43:14 +01:00
Douglas Duteil 14f8bcc40a chore(package): bump reflect-metadata version
Closes #4885
2015-10-27 13:34:41 +00:00
Rob Wormald 6c7bc09f70 chore(package): update RxJS dependency version 2015-10-15 16:28:49 -07:00
Igor Minar da1272f368 build(analytics): add basic build-analytics to the project
This is pretty experimental, but the goal is to track the performance
of our build over time so that we can more easily track perf regressions.

Currently it's integrated only with gulp tasks, but I'd like to expand it
to tracking travis jobs, protractor/benchpress test runs, npm installs, etc.

No PII is being collected. And the data is collected via a Google Analytics
property owned by the Angular team account.

Closes #4672
2015-10-12 03:50:00 +00:00
Alex Eagle aab0c57aee fix(typings): add more missing typings.
This is the same bug pattern I reported in https://github.com/Microsoft/TypeScript/issues/5187

Closes #4636
2015-10-09 19:00:42 +00:00
Julie Ralph af1119063c chore(ci): update Protractor version, remove custom waits
The latest Protractor version supports waiting for Angular2 applications,
so remove custom waiting logic.

Closes #3829
2015-10-07 13:08:58 -07:00
Victor Berchet fd5cd84065 chore(zone.js): update to 0.5.8
fixes #4531
2015-10-06 11:16:38 -07:00
Igor Minar 4b0013c7e7 build(npm): resolve shrinkwrap conflicts after rebase 2015-10-03 21:33:57 +00:00
Igor Minar 5ff1eb75d0 build(npm): upgrade gulp-sass to v2.0.4 2015-10-03 21:33:57 +00:00
Igor Minar 1b20873433 build(npm): update chokidar and karma* dependencies
These dependencies required upgrade in order for us to run on Node v4.x

chokidar 1.0.1 -> 1.1.0
karma 0.12.23 -> 0.13.10
karma-chorome-launcher 0.1.8 -> 0.2.0
karma-cli 0.0.4 -> 0.1.0
karma-dart 0.2.8 -> 0.3.0
karma-sauce-launcher 0.2.11 -> 0.2.14
2015-10-03 21:33:57 +00:00
Alex Eagle 7c4199cd1c chore(typings): remove StringMap
This was a poorly typed attempt to mimic TypeScript's index signatures,
which we can use instead.
This eliminates a very strange type that we were exposing to users, but
not re-exporting through our public API.

Fixes #4483
2015-10-03 01:09:42 +00:00
Alex Eagle 9b7378d132 chore(typings): remove traceur-runtime.d.ts
fixes #4297

Closes #4415
2015-09-30 00:07:16 +00:00
Victor Berchet fb9796130d chore(zone.js): update to 0.5.7
fixes #4179

Closes #4418
2015-09-29 22:31:35 +00:00
Alex Eagle b4fe590b2d chore(ts): fix TODOs that were pending on 1.6 upgrade
Closes #4377
2015-09-29 03:23:25 +00:00
Victor Berchet cd0e9c9cd4 chore(zone.js): update zone.js to 0.5.6
Closes #4399
2015-09-29 00:14:38 +00:00
Alex Eagle 3dd9919bbd chore(ts2dart): remove hand-written ts2dart typings
Now that we are on TS 1.6, we can use the new node module resolution strategy.

Closes #4372
2015-09-25 23:47:41 +00:00
vsavkin 5bf6a3af15 chore(typescript): fixes dart failures and linter
Closes #4359
2015-09-25 20:15:55 +00:00
Alex Eagle 7a53f82516 chore(typescript 1.6 upgrade): fix build.js and docs 2015-09-25 20:15:55 +00:00
Alex Eagle 2ee32fb02c chore(typescript 1.6 upgrade): fix build.tools 2015-09-25 20:15:55 +00:00