Fix DawnTest HasToggleEnabled referencing the wrong device

It should reference the backendDevice as the |device| points to
the wire client device when the wire is used.

Bug: none
Change-Id: Iac6399df96ea0226d8b9ba8f6196185e43c41adb
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/34923
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
This commit is contained in:
Austin Eng 2020-12-04 02:07:20 +00:00 committed by Commit Bot service account
parent 3a915a67f5
commit f731a81c74
1 changed files with 1 additions and 1 deletions

View File

@ -709,7 +709,7 @@ bool DawnTestBase::IsAsan() const {
} }
bool DawnTestBase::HasToggleEnabled(const char* toggle) const { bool DawnTestBase::HasToggleEnabled(const char* toggle) const {
auto toggles = dawn_native::GetTogglesUsed(device.Get()); auto toggles = dawn_native::GetTogglesUsed(backendDevice);
return std::find_if(toggles.begin(), toggles.end(), [toggle](const char* name) { return std::find_if(toggles.begin(), toggles.end(), [toggle](const char* name) {
return strcmp(toggle, name) == 0; return strcmp(toggle, name) == 0;
}) != toggles.end(); }) != toggles.end();