From eecf4b1e666211a13afa56f93477c55e8fd01621 Mon Sep 17 00:00:00 2001 From: HampusM Date: Thu, 2 Jun 2022 19:51:54 +0200 Subject: feat: implement game of life --- test/mocks/matrix.hpp | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 test/mocks/matrix.hpp (limited to 'test/mocks/matrix.hpp') diff --git a/test/mocks/matrix.hpp b/test/mocks/matrix.hpp new file mode 100644 index 0000000..1602ebf --- /dev/null +++ b/test/mocks/matrix.hpp @@ -0,0 +1,31 @@ +#pragma once + +#include "interfaces/matrix.hpp" + +#include + +template +class MockMatrix : public IMatrix +{ +public: + // NOLINTNEXTLINE(modernize-use-trailing-return-type) + MOCK_METHOD(void, fill, (Element element), (noexcept, override)); + + // NOLINTNEXTLINE(modernize-use-trailing-return-type) + MOCK_METHOD(Element, get, (const Vector2 &pos), (const, noexcept, override)); + + // NOLINTNEXTLINE(modernize-use-trailing-return-type) + MOCK_METHOD(void, set, (const Vector2 &pos, Element element), (noexcept, override)); + + // NOLINTNEXTLINE(modernize-use-trailing-return-type) + MOCK_METHOD(uint32_t, get_row_cnt, (), (const, noexcept, override)); + + // NOLINTNEXTLINE(modernize-use-trailing-return-type) + MOCK_METHOD(uint32_t, get_column_cnt, (), (const, noexcept, override)); + + // NOLINTNEXTLINE(modernize-use-trailing-return-type) + MOCK_METHOD(MatrixIterator, begin, (), (const, noexcept, override)); + + // NOLINTNEXTLINE(modernize-use-trailing-return-type) + MOCK_METHOD(MatrixIterator, end, (), (const, noexcept)); +}; -- cgit v1.2.3-18-g5258