Commit Graph

10 Commits

Author SHA1 Message Date
Kevin Lubick
83cee23c98 [bazel] Run buildifier on BUILD.bazel files
buildifier --lint=fix -r .

Change-Id: I6a41858270d20137978f8271c8f6160b51120777
Bug: skia:12541
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/529751
Reviewed-by: Ben Wagner <bungeman@google.com>
2022-04-14 18:13:43 +00:00
Kevin Lubick
b98328a27b [bazel] Add license to all our BUILD.bazel files
find -name "BUILD.bazel" -exec sed -i -e '1i licenses(["notice"])\n' {} +

Change-Id: Ie48f163b7d8d6ede9ba5f952e87232dd5c9fa8e6
Bug: skia:12541
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/529808
Reviewed-by: Ben Wagner <bungeman@google.com>
2022-04-13 19:50:29 +00:00
Kevin Lubick
5fb37db69f [bazel] Use bazel to build task drivers
One very important, but agonizing to discover, change was
to go_repositories.bzl. Without it, we see cryptic errors like:
external/org_chromium_go_luci/cipd/api/cipd/v1/BUILD.bazel:22:17: no such package '@org_chromium_go_luci//go.chromium.org/luci/cipd/api/cipd/v1': BUILD file not found in directory 'go.chromium.org/luci/cipd/api/cipd/v1' of external repository @org_chromium_go_luci. Add a BUILD file to a directory to mark it as a package. and referenced by '@org_chromium_go_luci//cipd/api/cipd/v1:api_go_proto'

The rest of these changes are very similar to
https://skia-review.googlesource.com/c/buildbot/+/514074
which also has justification for the use of task drivers,
even in a Bazel-driven world.

All the BUILD.bazel files under infra/bots/task_drivers were
generated by Gazelle.

Note that the infra/bots/BUILD.bazel can happily build and
package up the task drivers from the infra repo. The old
build_task_drivers tasks did this too, because we have some
task drivers that are used in both repos.

Change-Id: I13c46c62bc7a6a4bfe7935b28efbfb34caabb6f2
Bug: skia:12541
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/515296
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Kevin Lubick <kjlubick@google.com>
2022-03-03 16:12:18 +00:00
Kevin Lubick
d6af8bf966 [infra] Make jobs use Gold's public hashes
Change-Id: Ia5da00913d0b96e9edc47f8b2274bd26c35c251c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469457
Commit-Queue: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
2021-11-09 17:50:55 +00:00
Kevin Lubick
66125eac15 [canvaskit] Specify gold url and bucket for uploading
A previous change to goldctl removed the special-casing for
Skia, so we need to specify it ourselves.

Change-Id: If4d122daa4ee4bb865b628b7c6ee1cbe5d44d670
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409396
Reviewed-by: Ravi Mistry <rmistry@google.com>
2021-05-18 12:49:08 +00:00
Nathaniel Nifong
50940aba5d fix a few failing gm tests in wasm
The skia gn/ninja build step and the emscripten build step were using
a different set of defines. this violated assumptions of a couple of
tests

Change-Id: Id5364c0e1281b2e4024685fe8f106ee55c4961cb
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/338343
Commit-Queue: Nathaniel Nifong <nifong@google.com>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
2021-01-09 02:48:38 +00:00
Kevin Lubick
dffd20efe9 [canvaskit] Add unit tests to wasm_gm_tests
There are currently many tests skipped, but many more pass.
This changes the built binary to have a lot of debugging logic
in it so we should be able to get backtraces on those crashes
more easily when debugging.

gmtests.html was removed as it was superceded by run-wasm-gm-tests
and make run_local.

Bug: skia:10812, skia:10869
Change-Id: I72ab34d3db83a654dc8829831b3ecb795fe23d43
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/329170
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Nathaniel Nifong <nifong@google.com>
Commit-Queue: Kevin Lubick <kjlubick@google.com>
2020-11-02 16:51:23 +00:00
Kevin Lubick
bffc116a4a [canvaskit] Load resources into wasm gms/unit tests.
To load in the resources, we have the Node JS script
find all files in the provided resources directory and serve
that as a JSON file (the HTML JS can't list files easily).
The HTML JS reads that file, then loads all those files as
ArrayBuffers.

After the testing WASM and the resources all load, we pre-load
them into the WASM memory, assigned with their name. This is
just a map of name -> SkData. The WASM code can't (easily)
make fetch calls, so rather than load these resources on demand
like we would in a real file system, we pre-load them all
and serve them from RAM. For simplicity (and consistency with
the known_hashes), this map is a global.

Finally, to connect the resources to the GMs, we overwrite the
gResourceFactory (defined in ResourceFactory.h) which is used
by tools/Resources.cpp to load any resource file (in theory).

One more change is to write some progress steps to window._log
so it can be read by puppeteer and dumped to disk to aid in
debugging.

Bug: skia:10812
Change-Id: Ie22c7f4b8d7cbbd18173b4e2ed755105c1b45249
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/328901
Reviewed-by: Leandro Lovisolo <lovisolo@google.com>
2020-10-21 20:40:29 +00:00
Kevin Lubick
ffad5d3b2d [canvaskit] Fix gm test runner on non-tryjobs
Bug: skia:10812
Change-Id: I5e859fe96bb0f0f78f5da658a2fa4f77324bb439
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/328896
Reviewed-by: Eric Boren <borenet@google.com>
2020-10-21 11:31:27 +00:00
Kevin Lubick
bb9769fb21 [canvaskit] Add task driver for running GMs on WASM/WebGL.
This loads in the known digests from Gold, starts the test
harness (which runs the GMs using puppeteer) and then uses
goldctl to upload the results to Gold when finished.

This will fail (and should not be landed) until
https://skia-review.googlesource.com/c/buildbot/+/328156
makes it into goldctl and the cipd build.

Bug: skia:10812
Change-Id: I89e5cf188d8f2adeba4ff676525d9bfbdcb46d5a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/328380
Reviewed-by: Leandro Lovisolo <lovisolo@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
2020-10-20 15:25:30 +00:00