diff --git a/.github/workflows/arch.yml b/.github/workflows/arch.yml index 92e1e84..9a65cf4 100644 --- a/.github/workflows/arch.yml +++ b/.github/workflows/arch.yml @@ -30,6 +30,7 @@ jobs: rm -rf ./build CC="/usr/bin/clang" CXX="/usr/bin/clang++" cmake --no-warn-unused-cli -DCMAKE_BUILD_TYPE:STRING=Release -S . -B ./build CC="/usr/bin/clang" CXX="/usr/bin/clang++" cmake --build ./build --config Release --target all -j`nproc 2>/dev/null || getconf NPROCESSORS_CONF` + rm ./build/hyprlang.so - name: Run tests run: | @@ -63,6 +64,7 @@ jobs: rm -rf ./build CC="/usr/bin/gcc" CXX="/usr/bin/g++" cmake --no-warn-unused-cli -DCMAKE_BUILD_TYPE:STRING=Release -S . -B ./build CC="/usr/bin/gcc" CXX="/usr/bin/g++" cmake --build ./build --config Release --target all -j`nproc 2>/dev/null || getconf NPROCESSORS_CONF` + rm ./build/hyprlang.so - name: Run tests run: | diff --git a/tests/main.cpp b/tests/main.cpp index dbebe2c..7570449 100644 --- a/tests/main.cpp +++ b/tests/main.cpp @@ -55,8 +55,16 @@ int main(int argc, char** argv, char** envp) { std::cout << "Starting test\n"; Hyprlang::CConfig config("./config/config.conf"); - pConfig = &config; - currentPath = std::filesystem::canonical("./config/"); + + try { + pConfig = &config; + currentPath = std::filesystem::canonical("./config/"); + } catch (std::logic_error& e) { + std::cout << "err " << e.what() << std::endl; + return 1; + } + + std::cout << "start add" << std::endl; // setup config config.addConfigValue("testInt", 0L);