Commit Graph

4 Commits

Author SHA1 Message Date
Ben Clayton 54f4a21ee0 tools: Shuffle go code into an idiomatic tree
main packages usually go under a `cmd` directory.
Hoist utility packages to the root `src` directroy so they can be shared.

Change-Id: I0c221f6cd39980f5c202c030cd5134d775533efa
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/50901
Commit-Queue: Ben Clayton <bclayton@google.com>
Reviewed-by: David Neto <dneto@google.com>
2021-05-14 18:47:33 +00:00
Ben Clayton 434cd396fe Move tools to a tools/src directory
Allows bash scripts to share the same name as the directory.

Add fix-tests bash script.

Change-Id: Iaf1943d50ec1fd3f382a2c7823fb7cdd13b1d9a2
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/47766
Commit-Queue: Ben Clayton <bclayton@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
2021-04-16 10:42:24 +00:00
Ben Clayton 4485fcde64 fix-tests: Attempt to fix tests that use HasSubstr()
By comparing the old substring to the new full body, we can do a pretty
good job at creating a new substring.
This is not an exact science. Always carefully examine the newly
generated strings for correctness.

Change-Id: I8bdf591539a32ec42d0444aa054d88a933e4d250
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/47765
Commit-Queue: Ben Clayton <bclayton@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
2021-04-16 08:58:44 +00:00
Ben Clayton 5c3a7459e6 Add tools/fix-tests
A simple regex based tool for fixing unit tests that fail due to unexpected output

Change-Id: I72c47abaff6d6f4ba8cd497240eadc171af0fec3
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/47629
Commit-Queue: Ben Clayton <bclayton@chromium.org>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
2021-04-13 18:48:17 +00:00