TestHelper.hpp 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. /*
  2. * Author: Patrick-Christopher Mattulat
  3. * Company: Lynar Studios
  4. * E-Mail: webmaster@lynarstudios.com
  5. * Created: 2020-08-15
  6. * Changed: 2020-08-15
  7. *
  8. * */
  9. #ifndef TEST_HELPER_HPP
  10. #define TEST_HELPER_HPP
  11. #include <string>
  12. class TestHelper {
  13. public:
  14. TestHelper() = default;
  15. ~TestHelper() = default;
  16. static std::string getResourcesFolderLocation() {
  17. std::string location {};
  18. #ifdef _WIN32
  19. location = TestHelper::getTestFolderLocation() + R"(resources\)";
  20. #endif
  21. #ifdef unix
  22. location = TestHelper::getTestFolderLocation() + R"(resources/)";
  23. #endif
  24. return location;
  25. }
  26. static std::string getTestFolderLocation() {
  27. std::string location {};
  28. #ifdef _WIN32
  29. location = R"(C:\Users\drums\CLionProjects\lynar-studios-standard-library\test\)";
  30. #endif
  31. #ifdef unix
  32. location = R"(/home/patrick/CLionProjects/lynar-studios-standard-library/test/)";
  33. #endif
  34. return location;
  35. }
  36. };
  37. #endif