mirror of
https://github.com/hyprwm/hyprlang.git
synced 2024-11-17 02:25:59 +01:00
tests: adjust env check
This commit is contained in:
parent
069cb99131
commit
4d9da8db25
2 changed files with 2 additions and 2 deletions
|
@ -9,7 +9,7 @@ $MY_VAR = 1337
|
||||||
$MY_VAR_2 = $MY_VAR
|
$MY_VAR_2 = $MY_VAR
|
||||||
testVar = $MY_VAR$MY_VAR_2
|
testVar = $MY_VAR$MY_VAR_2
|
||||||
|
|
||||||
testEnv = $XDG_SESSION_TYPE
|
testEnv = $SHELL
|
||||||
|
|
||||||
testCategory {
|
testCategory {
|
||||||
testValueInt = 123456
|
testValueInt = 123456
|
||||||
|
|
|
@ -118,7 +118,7 @@ int main(int argc, char** argv, char** envp) {
|
||||||
EXPECT(std::any_cast<int64_t>(config.getConfigValue("testVar")), 1337420);
|
EXPECT(std::any_cast<int64_t>(config.getConfigValue("testVar")), 1337420);
|
||||||
|
|
||||||
// test env variables
|
// test env variables
|
||||||
EXPECT(std::any_cast<const char*>(config.getConfigValue("testEnv")), std::string{"wayland"});
|
EXPECT(std::any_cast<const char*>(config.getConfigValue("testEnv")), std::string{getenv("SHELL")});
|
||||||
|
|
||||||
} catch (const char* e) {
|
} catch (const char* e) {
|
||||||
std::cout << Colors::RED << "Error: " << Colors::RESET << e << "\n";
|
std::cout << Colors::RED << "Error: " << Colors::RESET << e << "\n";
|
||||||
|
|
Loading…
Reference in a new issue