Factor compilation of ~MockProcTable in mock_webgpu.cpp

GMock generates a lot of code in the destuctor of mock classes, so
factor that in mock_webgpu.cpp instead of compiling the code once for
each file including mock_webgpu.h.

Bug: None
Change-Id: I2b5984e911020eb33457bde9c6a45beaa93b3071
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/19725
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
This commit is contained in:
Corentin Wallez 2020-04-16 18:08:23 +00:00 committed by Commit Bot service account
parent 955f8a37cc
commit 3741f7373c
2 changed files with 4 additions and 2 deletions

View File

@ -149,8 +149,9 @@ void ProcTableAsClass::CallFenceOnCompletionCallback(WGPUFence fence,
}
{% endfor %}
MockProcTable::MockProcTable() {
}
MockProcTable::MockProcTable() = default;
MockProcTable::~MockProcTable() = default;
void MockProcTable::IgnoreAllReleaseCalls() {
{% for type in by_category["object"] %}

View File

@ -116,6 +116,7 @@ class ProcTableAsClass {
class MockProcTable : public ProcTableAsClass {
public:
MockProcTable();
~MockProcTable() override;
void IgnoreAllReleaseCalls();