diff options
| author | Joel Klinghed <the_jk@spawned.biz> | 2025-10-07 19:58:28 +0200 |
|---|---|---|
| committer | Joel Klinghed <the_jk@spawned.biz> | 2025-10-19 00:13:47 +0200 |
| commit | 4f6e76493fb74f5385d5a14dce3a01c9901802ed (patch) | |
| tree | a38722ec832fd44ad34257730e075e8b07825bd0 /test/testenv.hh | |
| parent | c87f9627efc8b612eb9b000acfcc6731cad15765 (diff) | |
paths: New module
Path utilities (doh)
Diffstat (limited to 'test/testenv.hh')
| -rw-r--r-- | test/testenv.hh | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/test/testenv.hh b/test/testenv.hh new file mode 100644 index 0000000..abe0bc8 --- /dev/null +++ b/test/testenv.hh @@ -0,0 +1,22 @@ +#ifndef TESTENV_HH +#define TESTENV_HH + +#include <gtest/gtest.h> +#include <map> +#include <optional> +#include <string> + +class TestEnv : public testing::Test { + protected: + void setenv(std::string const& name, std::string const& value); + void unsetenv(std::string const& name); + + void TearDown() override; + + private: + void saveenv(std::string const& name); + + std::map<std::string, std::optional<std::string>> env_; +}; + +#endif // TESTENV_HH |
