aboutsummaryrefslogtreecommitdiffstats
path: root/util/system/env_ut.cpp
diff options
context:
space:
mode:
authorVlad Yaroslavlev <vladon@vladon.com>2022-02-10 16:46:25 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:46:25 +0300
commit344ea37b4a345701ab0e67de2266a1c1bd7baf2d (patch)
tree1a2c5ffcf89eb53ecd79dbc9bc0a195c27404d0c /util/system/env_ut.cpp
parent706b83ed7de5a473436620367af31fc0ceecde07 (diff)
downloadydb-344ea37b4a345701ab0e67de2266a1c1bd7baf2d.tar.gz
Restoring authorship annotation for Vlad Yaroslavlev <vladon@vladon.com>. Commit 2 of 2.
Diffstat (limited to 'util/system/env_ut.cpp')
-rw-r--r--util/system/env_ut.cpp32
1 files changed, 16 insertions, 16 deletions
diff --git a/util/system/env_ut.cpp b/util/system/env_ut.cpp
index 3139394bc7..e03cc01658 100644
--- a/util/system/env_ut.cpp
+++ b/util/system/env_ut.cpp
@@ -1,31 +1,31 @@
#include <library/cpp/testing/unittest/registar.h>
-#include <util/generic/string.h>
+#include <util/generic/string.h>
#include "env.h"
Y_UNIT_TEST_SUITE(EnvTest) {
Y_UNIT_TEST(GetSetEnvTest) {
- TString key = "util_GETENV_TestVar";
- TString value = "Some value for env var";
- TString def = "Some default value for env var";
+ TString key = "util_GETENV_TestVar";
+ TString value = "Some value for env var";
+ TString def = "Some default value for env var";
// first of all, it should be clear
- UNIT_ASSERT_VALUES_EQUAL(GetEnv(key), TString());
+ UNIT_ASSERT_VALUES_EQUAL(GetEnv(key), TString());
UNIT_ASSERT_VALUES_EQUAL(GetEnv(key, def), def);
SetEnv(key, value);
// set and see what value we get here
UNIT_ASSERT_VALUES_EQUAL(GetEnv(key), value);
UNIT_ASSERT_VALUES_EQUAL(GetEnv(key, def), value);
// set empty value
- SetEnv(key, TString());
- UNIT_ASSERT_VALUES_EQUAL(GetEnv(key), TString());
-
- // check for long values, see IGNIETFERRO-214
- TString longKey = "util_GETENV_TestVarLong";
- TString longValue{1500, 't'};
- UNIT_ASSERT_VALUES_EQUAL(GetEnv(longKey), TString());
- SetEnv(longKey, longValue);
- UNIT_ASSERT_VALUES_EQUAL(GetEnv(longKey), longValue);
- SetEnv(longKey, TString());
- UNIT_ASSERT_VALUES_EQUAL(GetEnv(longKey), TString());
+ SetEnv(key, TString());
+ UNIT_ASSERT_VALUES_EQUAL(GetEnv(key), TString());
+
+ // check for long values, see IGNIETFERRO-214
+ TString longKey = "util_GETENV_TestVarLong";
+ TString longValue{1500, 't'};
+ UNIT_ASSERT_VALUES_EQUAL(GetEnv(longKey), TString());
+ SetEnv(longKey, longValue);
+ UNIT_ASSERT_VALUES_EQUAL(GetEnv(longKey), longValue);
+ SetEnv(longKey, TString());
+ UNIT_ASSERT_VALUES_EQUAL(GetEnv(longKey), TString());
}
}