Files
compute-runtime/shared/test/unit_test/test_macros/test_checks_shared.h
Maciej Dziuban 8fcd51c2c8 Do not obtain command stream if it will not be needed
Change-Id: Id7fa1c6b78e71a085084f8fcb66a7b8e873ad2bc
Signed-off-by: Maciej Dziuban <maciej.dziuban@intel.com>
Related-To: NEO-5120
2020-10-08 12:24:03 +02:00

35 lines
860 B
C++

/*
* Copyright (C) 2020 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
*/
#pragma once
#include "gtest/gtest.h"
#include <memory>
namespace NEO {
class Device;
struct HardwareInfo;
namespace TestChecks {
bool supportsBlitter(const HardwareInfo *pHardwareInfo);
bool supportsSvm(const HardwareInfo *pHardwareInfo);
bool supportsSvm(const std::unique_ptr<HardwareInfo> &pHardwareInfo);
bool supportsSvm(const Device *pDevice);
} // namespace TestChecks
} // namespace NEO
#define REQUIRE_SVM_OR_SKIP(param) \
if (NEO::TestChecks::supportsSvm(param) == false) { \
GTEST_SKIP(); \
}
#define REQUIRE_BLITTER_OR_SKIP(param) \
if (NEO::TestChecks::supportsBlitter(param) == false) { \
GTEST_SKIP(); \
}