Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/jp7677/dxvk-nvapi.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJens Peters <jp7677@gmail.com>2022-07-01 12:04:26 +0300
committerJens Peters <jp7677@gmail.com>2022-07-01 12:04:26 +0300
commit6e1979393a5027cbed5bb4201e44b542f6878673 (patch)
tree61c37e80f85a7dd36e3f88e4be5cbe2274d4bc55
parentb95890c66011702bc95036526d135a600bb1ff99 (diff)
tests: Set nvmlDevice for NVML tests
Otherwise unit-tests fail later on NvapiAdapter::HasNvmlDevice(). Strangely this only happens when the test suite runs with wine-nvml being available. Not really sure why...
-rw-r--r--tests/nvapi_sysinfo.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/nvapi_sysinfo.cpp b/tests/nvapi_sysinfo.cpp
index fd990b9..fbaad45 100644
--- a/tests/nvapi_sysinfo.cpp
+++ b/tests/nvapi_sysinfo.cpp
@@ -745,6 +745,7 @@ TEST_CASE("Sysinfo methods succeed", "[.sysinfo]") {
ALLOW_CALL(*nvml, IsAvailable()) // NOLINT(bugprone-use-after-move)
.RETURN(true);
ALLOW_CALL(*nvml, DeviceGetHandleByPciBusId_v2(_, _))
+ .SIDE_EFFECT(*_2 = reinterpret_cast<nvmlDevice_t>(0x1234)) // Just a non-nullptr
.RETURN(NVML_SUCCESS);
SECTION("GetGpuCoreCount returns OK") {