summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2025-03-03 23:22:31 +0100
committerCarl Hetherington <cth@carlh.net>2025-03-08 00:12:07 +0100
commit7d88bebfeb9931a39c6adc1e9dc9d6e1c0e3ea71 (patch)
tree7fb0716728ca91a30490b15fd8682c860f7d57e4 /test
parenteef48c36012180d20001def874864607e15968b8 (diff)
Get gpu_lister path from config.
Diffstat (limited to 'test')
-rw-r--r--test/grok_util_test.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/test/grok_util_test.cc b/test/grok_util_test.cc
index 8fba372a9..2a84fe2a4 100644
--- a/test/grok_util_test.cc
+++ b/test/grok_util_test.cc
@@ -19,6 +19,7 @@
*/
+#include "lib/config.h"
#include "lib/grok/util.h"
#include "test.h"
#include <boost/test/unit_test.hpp>
@@ -27,7 +28,13 @@
#ifdef DCPOMATIC_GROK
BOOST_AUTO_TEST_CASE(get_gpu_names_test)
{
- auto names = get_gpu_names("test/gpu_lister");
+ ConfigRestorer cr;
+
+ Config::Grok grok;
+ grok.binary_location = "test";
+ Config::instance()->set_grok(grok);
+
+ auto names = get_gpu_names();
BOOST_REQUIRE_EQUAL(names.size(), 3U);
BOOST_CHECK_EQUAL(names[0], "Foo bar baz");
BOOST_CHECK_EQUAL(names[1], "Spondoolix Mega Kompute 2000");