Move tint unittest behind a build flag.

This CL moves the Tint unittest code behind a build flag in order
to hide the //testing/test.gni dependency from downstream consumers.

The unittests are enabled by default and can be disabled by setting
`tint_build_unittests` to false.

Bug: dawn:1517
Change-Id: Id560ed98416ba0725b62a93ddd27caf341699e75
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/94481
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Auto-Submit: Dan Sinclair <dsinclair@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
This commit is contained in:
dan sinclair 2022-06-22 12:40:43 +00:00 committed by Dawn LUCI CQ
parent 32bcc0413d
commit 77bf233cef
3 changed files with 805 additions and 792 deletions

View File

@ -19,3 +19,5 @@ tint_build_spv_reader = true
tint_build_spv_writer = true
tint_build_wgsl_reader = true
tint_build_wgsl_writer = true
tint_build_unittests = true

File diff suppressed because it is too large Load Diff

View File

@ -71,4 +71,9 @@ declare_args() {
if (!defined(tint_build_glsl_writer)) {
tint_build_glsl_writer = true
}
# Build unittests
if (!defined(tint_build_unittests)) {
tint_build_unittests = true
}
}