aboutsummaryrefslogtreecommitdiffstats
path: root/yt/cpp/mapreduce/interface/config_ut.cpp
blob: e49ba0210805c6bbaa02607f37c312c774d1c63a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#include <library/cpp/testing/unittest/registar.h>

#include <yt/cpp/mapreduce/interface/config.h>

using namespace NYT;

Y_UNIT_TEST_SUITE(ConfigSuite)
{
    Y_UNIT_TEST(TestReset) {
        // very limited test, checks only one config field

        auto origConfig = *TConfig::Get();
        TConfig::Get()->Reset();
        UNIT_ASSERT_VALUES_EQUAL(origConfig.Hosts, TConfig::Get()->Hosts);

        TConfig::Get()->Hosts = "hosts/fb867";
        TConfig::Get()->Reset();
        UNIT_ASSERT_VALUES_EQUAL(origConfig.Hosts, TConfig::Get()->Hosts);
    }
}