puppeteer/packages/ng-schematics
dependabot[bot] 69b03dff93
chore(deps): Bump @angular-devkit/schematics from 15.0.3 to 15.0.4 (#9420)
Bumps
[@angular-devkit/schematics](https://github.com/angular/angular-cli)
from 15.0.3 to 15.0.4.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/angular/angular-cli/releases"><code>@​angular-devkit/schematics</code>'s
releases</a>.</em></p>
<blockquote>
<h2>v15.0.4</h2>
<p><!-- raw HTML omitted --><!-- raw HTML omitted --></p>
<h1>15.0.4 (2022-12-14)</h1>
<h3><code>@​angular-devkit/build-angular</code></h3>
<table>
<thead>
<tr>
<th>Commit</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a
href="ccc8e03508"><img
src="https://img.shields.io/badge/ccc8e0350-fix-green" alt="fix -
ccc8e0350" /></a></td>
<td>display actionable error when a style does not exist in Karma
builder</td>
</tr>
<tr>
<td><a
href="507f756c34"><img
src="https://img.shields.io/badge/507f756c3-fix-green" alt="fix -
507f756c3" /></a></td>
<td>downlevel class private methods when targeting Safari &lt;=v15</td>
</tr>
<tr>
<td><a
href="a0da91dba3"><img
src="https://img.shields.io/badge/a0da91dba-fix-green" alt="fix -
a0da91dba" /></a></td>
<td>include sources in generated Sass source maps</td>
</tr>
<tr>
<td><a
href="9fd3562342"><img
src="https://img.shields.io/badge/9fd356234-fix-green" alt="fix -
9fd356234" /></a></td>
<td>only set ngDevMode when script optimizations are enabled</td>
</tr>
<tr>
<td><a
href="8e85f47284"><img
src="https://img.shields.io/badge/8e85f4728-fix-green" alt="fix -
8e85f4728" /></a></td>
<td>update <code>css-loader</code> to <code>6.7.3</code></td>
</tr>
<tr>
<td><a
href="b2d4415caa"><img
src="https://img.shields.io/badge/b2d4415ca-fix-green" alt="fix -
b2d4415ca" /></a></td>
<td>update locale setting snippet to use <code>globalThis</code>.</td>
</tr>
</tbody>
</table>
<h2>Special Thanks</h2>
<p>Alan Agius and Charles Lyding</p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/angular/angular-cli/blob/main/CHANGELOG.md"><code>@​angular-devkit/schematics</code>'s
changelog</a>.</em></p>
<blockquote>
<h1>15.0.4 (2022-12-14)</h1>
<h3><code>@​angular-devkit/build-angular</code></h3>
<table>
<thead>
<tr>
<th>Commit</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a
href="ccc8e03508">ccc8e0350</a></td>
<td>fix</td>
<td>display actionable error when a style does not exist in Karma
builder</td>
</tr>
<tr>
<td><a
href="507f756c34">507f756c3</a></td>
<td>fix</td>
<td>downlevel class private methods when targeting Safari &lt;=v15</td>
</tr>
<tr>
<td><a
href="a0da91dba3">a0da91dba</a></td>
<td>fix</td>
<td>include sources in generated</td>
</tr>
<tr>
<td><a
href="9fd3562342">9fd356234</a></td>
<td>fix</td>
<td>only set ngDevMode when script optimizations are enabled</td>
</tr>
<tr>
<td><a
href="8e85f47284">8e85f4728</a></td>
<td>fix</td>
<td>update <code>css-loader</code> to <code>6.7.3</code></td>
</tr>
<tr>
<td><a
href="b2d4415caa">b2d4415ca</a></td>
<td>fix</td>
<td>update locale setting snippet to use <code>globalThis</code>.</td>
</tr>
</tbody>
</table>
<h2>Special Thanks</h2>
<p>Alan Agius and Charles Lyding</p>
<!-- raw HTML omitted -->
<p><!-- raw HTML omitted --><!-- raw HTML omitted --></p>
<h1>15.1.0-next.2 (2022-12-08)</h1>
<h3><code>@​schematics/angular</code></h3>
<table>
<thead>
<tr>
<th>Commit</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a
href="5b18ce1545">5b18ce154</a></td>
<td>feat</td>
<td>add <code>guardType</code> as an alias of <code>implements</code> in
guard schematic</td>
</tr>
<tr>
<td><a
href="49b313f27a">49b313f27</a></td>
<td>fix</td>
<td>add missing import for functional interceptor spec</td>
</tr>
<tr>
<td><a
href="2f92fe7e58">2f92fe7e5</a></td>
<td>fix</td>
<td>add missing semicolon in functional guard/resolver/interceptor</td>
</tr>
</tbody>
</table>
<h3><code>@​angular-devkit/build-angular</code></h3>
<table>
<thead>
<tr>
<th>Commit</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a
href="97716969c2">97716969c</a></td>
<td>fix</td>
<td>default preserve symlinks to Node.js value for esbuild</td>
</tr>
<tr>
<td><a
href="cf2f30afc0">cf2f30afc</a></td>
<td>fix</td>
<td>downlevel class fields with Safari &lt;= v15 for esbuild</td>
</tr>
<tr>
<td><a
href="25eaaa24b5">25eaaa24b</a></td>
<td>fix</td>
<td>downlevel class properties when targeting Safari &lt;=v15</td>
</tr>
<tr>
<td><a
href="7a063238b8">7a063238b</a></td>
<td>fix</td>
<td>explicitly send options to JS transformer workers</td>
</tr>
<tr>
<td><a
href="ef99a68b46">ef99a68b4</a></td>
<td>fix</td>
<td>prevent optimization adding unsupported ECMASCript features</td>
</tr>
</tbody>
</table>
<h2>Special Thanks</h2>
<p>Alan Agius, Charles Lyding, Cédric Exbrayat, Dominic Elm, Doug Parker
and Paul Gschwendtner</p>
<!-- raw HTML omitted -->
<p><!-- raw HTML omitted --><!-- raw HTML omitted --></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="8771258776"><code>8771258</code></a>
release: cut the v15.0.4 release</li>
<li><a
href="8e85f47284"><code>8e85f47</code></a>
fix(<code>@​angular-devkit/build-angular</code>): update
<code>css-loader</code> to <code>6.7.3</code></li>
<li><a
href="9fd3562342"><code>9fd3562</code></a>
fix(<code>@​angular-devkit/build-angular</code>): only set ngDevMode
when script optimizati...</li>
<li><a
href="ccc8e03508"><code>ccc8e03</code></a>
fix(<code>@​angular-devkit/build-angular</code>): display actionable
error when a style doe...</li>
<li><a
href="507f756c34"><code>507f756</code></a>
fix(<code>@​angular-devkit/build-angular</code>): downlevel class
private methods when targ...</li>
<li><a
href="b2d4415caa"><code>b2d4415</code></a>
fix(<code>@​angular-devkit/build-angular</code>): update locale setting
snippet to use `glo...</li>
<li><a
href="a0da91dba3"><code>a0da91d</code></a>
fix(<code>@​angular-devkit/build-angular</code>): include sources in
generated</li>
<li>See full diff in <a
href="https://github.com/angular/angular-cli/compare/15.0.3...15.0.4">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@angular-devkit/schematics&package-manager=npm_and_yarn&previous-version=15.0.3&new-version=15.0.4)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-12-16 12:01:17 +01:00
..
src chore(ng-schematics): Spawn server when running ng e2e (#9306) 2022-11-23 13:10:03 +01:00
test/src chore(ng-schematics): Spawn server when running ng e2e (#9306) 2022-11-23 13:10:03 +01:00
.eslintignore chore: Add Jest as a ng-schematics option (#9257) 2022-11-11 14:38:52 +01:00
.gitignore chore(ng-schematics): Add Angular Schematics (#9222) 2022-11-09 14:52:10 +01:00
.mocharc.cjs chore(ng-schematics): Add Angular Schematics (#9222) 2022-11-09 14:52:10 +01:00
CHANGELOG.md chore: release main (#9313) 2022-11-23 14:14:25 +01:00
copySchemaFiles.js chore(ng-schematics): Add Angular Schematics (#9222) 2022-11-09 14:52:10 +01:00
package-lock.json chore: release main (#9313) 2022-11-23 14:14:25 +01:00
package.json chore(deps): Bump @angular-devkit/schematics from 15.0.3 to 15.0.4 (#9420) 2022-12-16 12:01:17 +01:00
README.md chore(ng-schematics): Spawn server when running ng e2e (#9306) 2022-11-23 13:10:03 +01:00
tsconfig.json chore(ng-schematics): Use WireIt for builds and tests (#9356) 2022-12-05 10:35:31 +01:00
tsconfig.spec.json chore(ng-schematics): Use WireIt for builds and tests (#9356) 2022-12-05 10:35:31 +01:00

Puppeteer Angular Schematic

Adds Puppeteer-based e2e tests to your Angular project.

Usage

Run the command bellow in an Angular CLI app directory and follow the prompts. Note this will add the schematic as a dependency to your project.

ng add @puppeteer/ng-schematics

Or you can use the same command followed by the options bellow.

Currently, this schematic supports the following test frameworks:

With the schematics installed you can run E2E tests:

ng e2e

Note: Command spawns it's own server on the same port ng serve does.

Options

When adding schematics to your project you can to provide following options:

Option Description Value Required
--isDefaultTester When true, replaces default ng e2e command. boolean true
--exportConfig When true, creates an empty Puppeteer configuration file. (.puppeteerrc.cjs) boolean true
--testingFramework The testing framework to install along side Puppeteer. "jasmine", "jest", "mocha", "node" true

Contributing

Check out our contributing guide to get an overview of what you need to develop in the Puppeteer repo.

Unit Testing

The schematics utilize @angular-devkit/schematics/testing for verifying correct file creation and package.json updates. To execute the test suit:

npm run test