Qt qcreator navigation/recognition is broken for all unit tests
|Status:||Archived||Start date:||08 Aug 2016|
Qt creator doesn't know about Core/Fit include files, auto completion is broken for all BornAgain classes in the context of unit tests.
- for example open LayerTest.h, try to navigate to Layer.h;
- Layer, HomogeneousMaterial etc will be show (in the text of given file) in normal font, no auto completion
#1 Updated by wuttke over 4 years ago
See also right-click-menu > Open Include Hierarchy (SHIFT+CTRL_I) on any source file.
For LayerTest.h, it says: Includes (none), Included by TestCore1.cpp.
Whereas for TestCore1.cpp, it has a correct list of Includes, among them LayerTest.h. And most remarkably, in an expandable list below LayerTest.h we find all the Includes that were incorrectly missing when we looked up for LayerTest.h.
#2 Updated by wuttke over 4 years ago
- Tracker changed from Bug to Configuration
Some web discussions suggest qtcreator has a problem with absolute paths; relative paths might help with this kind of problem.
This I tried in 0a0827c9 to no avail. Therefore reverted in ca6b118d to the usual absolute path in include_directories.
#4 Updated by wuttke over 4 years ago
- Status changed from Sprint to Resolved
- Target version set to Sprint32
Hopefully resolved in 4b73a91:
Google test wrapper replaced by a lighter macro.
Now each unit test subdirectory has an identical copy of main.cpp,
and a file testlist.h that consists of #include's of all other .h
files in the subdirectory.
For the time being, the files testlist.h are not automatically
updated, but there is a script dev-tools/code-tools/update-gtestlist.py
that can be run when needed.