Commit Graph
8 Commits
Author SHA1 Message Date
Sigurd Schneider 123977af32 Enforce naming convention in test/
Bug: chromium:1057042
Change-Id: Ib95f2640b1acf525cd12e377f0118377ddbe6077
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2695568
Reviewed-by: Mathias Bynens <mathias@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
2021-02-15 14:57:54 +00:00
Sigurd Schneider 1576186355 Enforce member delimiters
This CL enforces member delimiters following
https://google.github.io/styleguide/tsguide.html#member-property-declarations

Bug: chromium:1057042
Change-Id: I2553aeebb8187235cdf0e7f0585da36ea53388bb
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2672032
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Alex Rudenko <alexrudenko@chromium.org>
Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
2021-02-04 09:03:57 +00:00
Paul Lewis d2517fedec [perf] Restore boot perf test
We updated the e2e tests to using a different architecture a while ago
but we didn't update the boot perf tests to match. This CL migrates
them to using node_ts_library in the same way as e2e, sets the output
directory to be perf-data in the root of front_end, and ensures that
the JSON file contains mean and percentile data.

Change-Id: I0738ae664e52ec7a8fa76173a0155e14f583259f
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2546708
Auto-Submit: Paul Lewis <aerotwist@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
Commit-Queue: Paul Lewis <aerotwist@chromium.org>
2020-11-18 16:14:22 +00:00
Tim van der Lippe 6a935445b3 Port perf test suite to mocha runner
This resurrects the perf test suite, as the older test-runner setup
was removed, but the perf test suite was not ported.

Example output:

Spawning hosted mode server
  Boot performance
    ✓ run 1/37 (1185ms)
    ✓ run 2/37 (1234ms)
    ✓ run 3/37 (1213ms)
    ✓ run 4/37 (1376ms)
    ✓ run 5/37 (1327ms)
    ✓ run 6/37 (1235ms)
    ✓ run 7/37 (1352ms)
    ✓ run 8/37 (1439ms)
    ✓ run 9/37 (1332ms)
    ✓ run 10/37 (1290ms)
    ✓ run 11/37 (1229ms)
    ✓ run 12/37 (1241ms)
    ✓ run 13/37 (1233ms)
    ✓ run 14/37 (1203ms)
    ✓ run 15/37 (1177ms)
    ✓ run 16/37 (1336ms)
    ✓ run 17/37 (1526ms)
    ✓ run 18/37 (1465ms)
    ✓ run 19/37 (1537ms)
    ✓ run 20/37 (1709ms)
    ✓ run 21/37 (1760ms)
    ✓ run 22/37 (1704ms)
    ✓ run 23/37 (2549ms)
    ✓ run 24/37 (1387ms)
    ✓ run 25/37 (1934ms)
    ✓ run 26/37 (1860ms)
    ✓ run 27/37 (1309ms)
    ✓ run 28/37 (1295ms)
    ✓ run 29/37 (1391ms)
    ✓ run 30/37 (1569ms)
    ✓ run 31/37 (1562ms)
    ✓ run 32/37 (1442ms)
    ✓ run 33/37 (1431ms)
    ✓ run 34/37 (1646ms)
    ✓ run 35/37 (1927ms)
    ✓ run 36/37 (1600ms)
    ✓ run 37/37 (1587ms)
Mean boot time: 1475.28ms
50th percentile boot time: 1390.83ms
90th percentile boot time: 1860.02ms
99th percentile boot time: 2549.29ms

R=aerotwist@chromium.org

Change-Id: I1b6a79fdfc1b7c98f6156d3309b5b98ff8530476
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2209108
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-05-20 13:42:43 +00:00
Tim van der Lippe 869374bcab Port shared test runner logic into separate package
The shared test runner logic was reimplementing parts of Mocha,
in particular the test logging and filtering. Moreover, it was
booting the hosted mode server and puppeteer outside of Mocha.

Mocha supports root level hooks [1]. These hooks allow us to
perform work before a test starts. Moreover, by using the
before and after hook, we can run logic before and after
all tests.

By using these hooks, we can extract the "boot the hosted mode
server and hookup puppeteer" part to these root hooks.
Additionally, we can reset the pages in the `beforeEach`, which
means that tests themselves don't have to reset the pages.

We also put the implementation code into third_party/conductor,
as we would like to reuse this logic for the Puppeteer tests.
The Puppeteer test suite now also uses Mocha and has very
similar requirements as to our DevTools tests. By extracting
from DevTools, we can look into expanding the test runner to
other usecases, but that is out of scope for now.

[1]: https://mochajs.org/#root-level-hooks

Bug: 1071369

Change-Id: Ie9f954359d9de84da564b74b6f5517dd535db008
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2150458
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-04-20 10:32:58 +00:00
Tim van der Lippe 6d6a82eb64 Typecheck test/{perf,screenshots} with TypeScript
R=aerotwist@chromium.org

Bug: 1011811
Change-Id: Id506046ab1c35c753e145c3be6158705a4f55488
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2112559
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
2020-03-23 14:03:41 +00:00
Paul Lewis 1a3ae5481b Updates boot perf timing to be 2 decimal places
TBR=jacktfranklin@chromium.org

Change-Id: I23fe514682101becc24872fdd0048b19b988c5a9
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2078927
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
Commit-Queue: Paul Lewis <aerotwist@chromium.org>
2020-02-28 12:39:49 +00:00
Paul Lewis 65761161be [perf] Updates boot perf test
Change-Id: I7d8f9cf62638230a1d912c7c12beca02a2883bfa
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2077658
Commit-Queue: Paul Lewis <aerotwist@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
2020-02-28 10:40:09 +00:00