aboutsummaryrefslogtreecommitdiffstats
path: root/util/system/progname_ut.cpp
blob: d058647facbcde184a487b6abfd9ef9f75c80ad9 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#include "progname.h"

#include <library/cpp/testing/unittest/registar.h>

Y_UNIT_TEST_SUITE(TProgramNameTest) {
    Y_UNIT_TEST(TestIt) {
        TString progName = GetProgramName(); 

        try {
            UNIT_ASSERT(
                progName.find("ut_util") != TString::npos || progName.find("util-system_ut") != TString::npos || progName.find("util-system-ut") != TString::npos); 
        } catch (...) {
            Cerr << progName << Endl;

            throw;
        }
    }
}