drogonframework / drogonframework/drogon
tests don't compile with -DUSE_SUBMODULE=NO
- Dominant language
- C++
- Stars
- 14.3k
- Forks
- 1.4k
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 14
Description
**Describe the bug**
* the tests want to copy `trantor/trantor/tests/server.pem` to the build directory
* `lib/tests/unittests/FileTypeTest.cc` [tries to include](https://github.com/drogonframework/drogon/blob/122a42cd4ffe31380ab6d13718ef1881b9723036/lib/tests/unittests/FileTypeTest.cc#L1) `../lib/src/HttpUtils.h` but the file is in `../../src/` (not sure why it works with trantor as submodule)
**To Reproduce**
Steps to reproduce the behavior:
1. install trantor
2. clone drogon repo and do not initialise its trantor submodule
3. `cmake -S . -DUSE_SUBMODULE=NO build && cmake ---build build`
4. it fails
**Expected behavior**
tests compile
**Desktop (please complete the following information):**
- OS: Gentoo Linux
**Additional context**
adding the include directory `${CMAKE_CURRENT_SOURCE_DIR}/..` to the [`unittest` target](https://github.com/drogonframework/drogon/blob/122a42cd4ffe31380ab6d13718ef1881b9723036/lib/tests/CMakeLists.txt#L44) fixed the second error.
Contributor guide
Assessment
This issue has not been assessed yet.