/
githubmirror
/
omim
Обзор
Документация
Войти
/
githubmirror
/
omim
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
drape/drape_tests/failure_reporter.cpp
40 строк
803 B
Maxim Pimenov
[base] Replaced the namespace my with base.
18 сен 2018, 14:46
18 сен 2018, 14:46
412387c
Код
Авторство
О чём код?
#include <gmock/internal/gmock-internal-utils.h> #include "testing/testing.hpp" namespace testing { namespace internal { class MwmFailureReporter : public FailureReporterInterface { bool m_throwed; public: MwmFailureReporter() : m_throwed(false) {} virtual void ReportFailure(FailureType type, char const * file, int line, string const & message) { if (!m_throwed) { m_throwed = true; base::OnTestFailed(base::SrcPoint(file == NULL ? "" : file, line, ""), message); } } }; FailureReporterInterface * GetFailureReporter() { static MwmFailureReporter reporter; return &reporter; } } // namespace internal } // namespace testing