ValidationTest: correctly assert deprecation warnings are emitted.

Bug: dawn:642
Change-Id: If8601c50e4a14b5de5098398381c7a6c5e1f73fd
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/44867
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Brandon Jones <bajones@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Brandon Jones <bajones@chromium.org>
This commit is contained in:
Corentin Wallez 2021-03-17 19:10:27 +00:00 committed by Commit Bot service account
parent 6e5d47a396
commit 3fe857a621
1 changed files with 2 additions and 1 deletions

View File

@ -45,10 +45,11 @@
do { \ do { \
FlushWire(); \ FlushWire(); \
size_t warningsBefore = dawn_native::GetDeprecationWarningCountForTesting(backendDevice); \ size_t warningsBefore = dawn_native::GetDeprecationWarningCountForTesting(backendDevice); \
EXPECT_EQ(mLastWarningCount, warningsBefore); \
statement; \ statement; \
FlushWire(); \ FlushWire(); \
size_t warningsAfter = dawn_native::GetDeprecationWarningCountForTesting(backendDevice); \ size_t warningsAfter = dawn_native::GetDeprecationWarningCountForTesting(backendDevice); \
EXPECT_EQ(mLastWarningCount, warningsBefore); \ EXPECT_EQ(warningsAfter, warningsBefore + 1); \
mLastWarningCount = warningsAfter; \ mLastWarningCount = warningsAfter; \
} while (0) } while (0)