Files
compute-runtime/shared/test/unit_test/test_stats.h
Fabian Zwolinski 3d8effcd69 Clean-Up unused code related to GMock
This commit:
- Removes usings e.g. ::testing::Return
- Removes unnecessary gmock inclues
- Replaces Gmock macros (e.g. EXPECT_THAT) with our custom implementations

Related-To: NEO-4941
Signed-off-by: Fabian Zwolinski <fabian.zwolinski@intel.com>
2022-03-22 16:16:34 +01:00

26 lines
908 B
C++

/*
* Copyright (C) 2021-2022 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
*/
#pragma once
#include "gtest/gtest.h"
#include <sstream>
#include <string>
std::string getTestStats() {
std::string output;
std::stringstream stream;
stream << "Total test count: " << ::testing::UnitTest::GetInstance()->total_test_count() << std::endl;
stream << "Test to run count: " << ::testing::UnitTest::GetInstance()->test_to_run_count() << std::endl;
stream << "Reportable test count: " << ::testing::UnitTest::GetInstance()->reportable_test_count() << std::endl;
stream << "Disabled test count: " << ::testing::UnitTest::GetInstance()->disabled_test_count() << std::endl;
stream << "Reportable disabled test count: " << ::testing::UnitTest::GetInstance()->reportable_disabled_test_count() << std::endl;
return stream.str();
}