Commit graph

8 commits

Author SHA1 Message Date
George Kalpakas
37e02750a7 build(docs-infra): fix SystemJS-based docs examples (#43868)
Previously, the SystemJS-based docs examples (typically `ngUpgrade`
examples) were not compatible with Angular v13 (due to the removal of
UMD bundles from the published packages).

This commit makes the examples compatible with Angular v13 and
re-enables the tests for all SystemJS-based examples on CI.

PR Close #43868
2021-11-08 17:01:16 +00:00
George Kalpakas
ef090d1347 test(docs-infra): improve debugging when docs example tests fail without exiting (#43683)
When the docs examples tests run with `--cliSpecsConcurrency` greater
than 1 (as happens on CI), the output of each process is [buffered][1]
(to avoid interleaved output from multiple, parallel processes) and is
only printed out once the process exits (either successfully or with an
error). However, in cases where a process did not exit, the buffered
output would be never printed out, thus making debugging the failure
harder. This is the case, for example, if a build error happens during
`ng e2e`. This can be seen in action in [this CI job][2], where the job
fails due to no output, but the error (which is an incompatible TS
version) is never printed out.

To make debugging such situations easier in the future, this commit
updates the `spawnExt()` helper to reject (causing the buffered output
to be printed out) if there is no output from the spawned process for
more than 5 minutes.

[1]: c721135e37/aio/tools/examples/run-example-e2e.mjs (L293)
[2]: https://circleci.com/gh/angular/angular/1061751

PR Close #43683
2021-10-06 10:04:47 -07:00
George Kalpakas
3be5716952 refactor(docs-infra): remove redundant code from run-example-e2e.mjs (#43683)
This commit removes some code that was unused or had no effect from the
`run-example-e2e.mjs` script.

PR Close #43683
2021-10-06 10:04:47 -07:00
Paul Gschwendtner
5b5adb17ec test(docs-infra): temporarily disable upgrade systemjs example e2e tests (#43431)
This commit temporarily disables the SystemJS upgrade e2e tests. All of
the upgrade e2e tests (except for `phonecat-1-typescript`) rely on UMD
bundles. These are no longer available for the v13 Angular package
output, so we disable the tests for now.

These e2e tests can be re-enabled once we migrated the exampels from
UMD bundles to e.g. the CLI, or some custom rollup build. Alternatively
it might be even possible to use FESM bundles directly (depending on
browser support for the AIO examples; this is something the docs-infra
team will have to determine though).

PR Close #43431
2021-10-01 18:28:46 +00:00
Paul Gschwendtner
72c12653e1 build(docs-infra): do not error if suites are ignored (#43431)
Adding suites to the `IGNORED_EXAMPLES` array currently results
in an runtime exception because later when ignored examples are
printed to stdout, a non-existent variable is referenced back
from when there were examples disabled due to the Ivy migration.

This commit fixes the logic.

PR Close #43431
2021-10-01 18:28:46 +00:00
George Kalpakas
93590895b5 build(docs-infra): update docs examples to Angular v12.1.3 (#42949)
This commit updates the docs examples to Angular v12.1.3. In addition to
updating the dependencies versions, it also updates the projects'
structure and configs to more closely match what a new v12 CLI app would
look like. See, also, the [diff][1] between a basic v11.2.11 CLI app and
a v12.1.3 one.

[1]: https://github.com/cexbrayat/angular-cli-diff/compare/11.2.11..12.1.3

PR Close #42949
2021-08-09 09:41:00 -07:00
Renovate Bot
648da4f8b5 build: update dependency globby to v12 (#42921)
PR Close #42921
2021-07-23 10:37:35 -07:00
George Kalpakas
19da73741d build(docs-infra): switch the example-e2e script to ESM (#42921)
Switch the JS script used for running the docs examples tests from
CommonJS to ESM format. This is necessary for upgrading the `globby`
dependency to [version 12.0.0][1] in a subsequent commit.

[1]: https://github.com/sindresorhus/globby/releases/v12.0.0

PR Close #42921
2021-07-23 10:37:35 -07:00
Renamed from aio/tools/examples/run-example-e2e.js (Browse further)