From faccf5f9c899c40d4da5792629d0714249a4616b Mon Sep 17 00:00:00 2001 From: MarcoFalke Date: Tue, 1 Oct 2019 16:11:12 -0400 Subject: doc: Explain QT_QPA_PLATFORM for gui tests --- src/qt/test/test_main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/qt/test/test_main.cpp') diff --git a/src/qt/test/test_main.cpp b/src/qt/test/test_main.cpp index 796cf24b36..3e6b3a2a12 100644 --- a/src/qt/test/test_main.cpp +++ b/src/qt/test/test_main.cpp @@ -63,7 +63,7 @@ int main(int argc, char *argv[]) #if defined(WIN32) _putenv_s("QT_QPA_PLATFORM", "minimal"); #else - setenv("QT_QPA_PLATFORM", "minimal", 0); + setenv("QT_QPA_PLATFORM", "minimal", /* overwrite */ 0); #endif // Don't remove this, it's needed to access -- cgit v1.2.3 From fa06bb607da2d3e35723661156d873c8eac1fa50 Mon Sep 17 00:00:00 2001 From: MarcoFalke Date: Tue, 1 Oct 2019 17:03:09 -0400 Subject: qa: Do not force overwrite of QT_QPA_PLATFORM on windows for gui tests --- src/qt/test/test_main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/qt/test/test_main.cpp') diff --git a/src/qt/test/test_main.cpp b/src/qt/test/test_main.cpp index 3e6b3a2a12..c39266a397 100644 --- a/src/qt/test/test_main.cpp +++ b/src/qt/test/test_main.cpp @@ -61,7 +61,7 @@ int main(int argc, char *argv[]) // platform ("xcb", "windows", or "cocoa") so tests can't unintentionally // interfere with any background GUIs and don't require extra resources. #if defined(WIN32) - _putenv_s("QT_QPA_PLATFORM", "minimal"); + if (getenv("QT_QPA_PLATFORM") == nullptr) _putenv_s("QT_QPA_PLATFORM", "minimal"); #else setenv("QT_QPA_PLATFORM", "minimal", /* overwrite */ 0); #endif -- cgit v1.2.3