cucumber-cpp icon indicating copy to clipboard operation
cucumber-cpp copied to clipboard

QTestDriver Implementation not working on Windows

Open kreuzberger opened this issue 10 months ago • 1 comments

👓 What did you see?

Using the provided QTestDriver Implementation for windows gives errors

Unable to open file for logging: %TEMP%/test_module_runner.XNlhxg

The filename test_module_runner comes from the executable name.

✅ What did you expect to see?

The file should be created and used for QTest logging.

📦 Which tool/library version are you using?

cucumber-cpp v0.7.0

🔬 How could we reproduce it?

run QTestDriver test

📚 Any additional context?

This fails cause the QTemporary File created in the QTestDriver implementation is not going ouf of scope and therefore exists and is opened by cucumber-cpp. qTestExec could not write to this file and give the above error from Qt Internals.

The Temporary file name should created another way or the QTemporary File must go out of scope to let windows access the file resource.

kreuzberger avatar Apr 08 '24 07:04 kreuzberger

Seems on windows the tests are not executed like for linux. Maybe add simple ctest call in the build script.

kreuzberger avatar Apr 08 '24 12:04 kreuzberger