@web/test-runner
TypeScript icon, indicating that this package has built-in type declarations

0.19.0 • Public • Published

Web Test Runner

Test runner for web applications.

👉   Headless browsers with Puppeteer, Playwright, or Selenium.
🚧   Reports logs, 404s, and errors from the browser.
🔍   Debug opens a real browser window with devtools.
📦   Mock es modules using Import Maps.
🔧   Exposes browser properties like viewport size and dark mode.
⏱  Runs tests in parallel and isolation.
👀   Interactive watch mode.
🏃   Fast development by rerunning only changed tests.
🚀   Powered by esbuild and rollup plugins

See our website for full documentation.

Installation

Install the web test runner:

npm i --save-dev @web/test-runner

Basic commands

Do a single test run:

web-test-runner test/**/*.test.js --node-resolve
wtr test/**/*.test.js --node-resolve

Run in watch mode, reloading on file changes:

web-test-runner test/**/*.test.js --node-resolve --watch
wtr test/**/*.test.js --node-resolve --watch

Run with code coverage profiling (this is slower):

web-test-runner test/**/*.test.js --node-resolve --coverage
wtr test/**/*.test.js --node-resolve --coverage

Transform JS to a compatible syntax based on user agent:

web-test-runner test/**/*.test.js --node-resolve --esbuild-target auto
wtr test/**/*.test.js --node-resolve --esbuild-target auto

Guide

Check out this step by step guide to get started.

Example projects

Check out the example projects for a fully integrated setup.

Documentation

See our website for full documentation.

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
0.19.037,253latest
0.13.16-next.0249next
0.0.0-canary-202402191045361canary

Version History

VersionDownloads (Last 7 Days)Published
0.19.037,253
0.18.322,331
0.18.27,001
0.18.11,488
0.0.0-canary-202402191045361
0.0.0-canary-202402191041261
0.0.0-canary-202402121719430
0.0.0-canary-202401051014121
0.0.0-canary-202401050952481
0.0.0-canary-202401050938230
0.0.0-canary-202401050926072
0.0.0-canary-202401050917251
0.0.0-canary-202311220936001
0.18.01,381
0.17.3420
0.17.248
0.17.1862
0.17.0158
0.16.1998
0.16.033
0.0.0-canary-202304201041360
0.0.0-canary-202304162229380
0.0.0-canary-202304051811240
0.0.0-canary-202304041344390
0.15.32,458
0.0.0-canary-202304041227260
0.0.0-canary-202304031435110
0.15.24
0.0.0-canary-202303281722550
0.0.0-canary-202303240031290
0.0.0-canary-202303211223340
0.0.0-canary-202303161756160
0.15.12,327
0.0.0-canary-202302221412050
0.15.0896
0.14.11,971
0.14.0189
0.13.312,146
0.13.30424
0.13.297
0.13.284
0.13.27491
0.13.26127
0.13.2515
0.13.241
0.13.230
0.13.22113
0.13.210
0.13.2033
0.13.190
0.13.1814
0.13.1758
0.0.0-canary-20217132026200
0.0.0-canary-20217132015291
0.13.164
0.0.0-canary-20217131344491
0.0.0-canary-20217131337140
0.13.16-next.0249
0.13.156
0.13.1335
0.13.121
0.13.111
0.13.100
0.13.92
0.13.80
0.13.70
0.13.62
0.13.6-next.020
0.13.521
0.13.48
0.13.3362
0.13.26
0.13.11
0.13.00
0.12.20666
0.12.1911
0.12.183
0.12.171
0.12.161
0.12.152
0.12.140
0.12.130
0.12.120
0.12.102
0.12.90
0.12.80
0.12.7169
0.12.61
0.12.51
0.12.40
0.12.33
0.12.264
0.12.10
0.12.00
0.11.786
0.11.61
0.11.519
0.11.41
0.11.32
0.11.20
0.11.10
0.11.01
0.10.276
0.10.12
0.10.01
0.9.13102
0.9.122
0.9.110
0.9.100
0.9.92
0.9.81
0.9.74
0.9.62
0.9.52
0.9.41
0.9.30
0.9.21
0.9.10
0.9.00
0.8.50
0.8.41
0.8.30
0.8.20
0.8.11
0.8.00
0.7.424
0.7.410
0.7.401
0.7.390
0.7.381
0.7.370
0.7.360
0.7.350
0.7.340
0.7.331
0.7.320
0.7.311
0.7.301
0.7.291
0.7.280
0.7.271
0.7.260
0.7.250
0.7.242
0.7.230
0.7.221
0.7.211
0.7.200
0.7.190
0.7.171
0.7.162
0.7.150
0.7.140
0.7.130
0.7.122
0.7.111
0.7.100
0.7.90
0.7.80
0.7.71
0.7.61
0.7.50
0.7.40
0.7.30
0.7.21
0.7.12
0.7.02
0.6.650
0.6.641
0.6.630
0.6.620
0.6.610
0.6.601
0.6.590
0.6.580
0.6.570
0.6.560
0.6.550
0.6.540
0.6.530
0.6.522
0.6.510
0.6.500
0.6.490
0.6.481
0.6.470
0.6.460
0.6.450
0.6.441
0.6.430
0.6.420
0.6.412
0.6.401
0.6.391
0.6.380
0.6.370
0.6.360
0.6.351
0.6.340
0.6.330
0.6.321
0.6.311
0.6.300
0.6.290
0.6.280
0.6.271
0.6.261
0.6.250
0.6.240
0.6.231
0.6.221
0.6.211
0.6.201
0.6.190
0.6.181
0.6.170
0.6.151
0.6.141
0.6.130
0.6.120
0.6.111
0.6.101
0.6.90
0.6.80
0.6.70
0.6.60
0.6.51
0.6.40
0.6.30
0.6.20
0.6.11
0.6.01
0.5.220
0.5.210
0.5.200
0.5.190
0.5.181
0.5.170
0.5.160
0.5.151
0.5.140
0.5.130
0.5.120
0.5.110
0.5.100
0.5.90
0.5.80
0.5.70
0.5.60
0.5.50
0.5.40
0.5.31
0.5.20
0.5.11
0.5.00
0.4.00
0.3.10
0.3.00
0.2.120
0.2.111
0.2.100
0.2.91
0.2.80
0.2.70
0.2.60
0.2.50
0.2.40
0.2.30
0.2.21
0.2.10
0.2.00
0.1.01

Package Sidebar

Install

npm i @web/test-runner

Weekly Downloads

85,274

Version

0.19.0

License

MIT

Unpacked Size

183 kB

Total Files

145

Last publish

Collaborators

  • d4kmor
  • passle
  • jorenbroekema
  • bennyp
  • larsdenbakker
  • westbrook
  • modern-web