@@ -13,7 +13,7 @@ namespace NLs {
13
13
14
14
using namespace NKikimr ;
15
15
16
- #define DESCRIBE_ASSERT_EQUAL ( name, type, expression, description ) \
16
+ #define DESCRIBE_ASSERT ( op, name, type, expression, description ) \
17
17
TCheckFunc name (type expected) { \
18
18
return [=] (const NKikimrScheme::TEvDescribeSchemeResult& record) { \
19
19
UNIT_ASSERT_C (IsGoodDomainStatus (record.GetStatus ()), " Unexpected status: " << record.GetStatus ()); \
@@ -22,13 +22,16 @@ using namespace NKikimr;
22
22
const auto & subdomain = pathDescr.GetDomainDescription (); \
23
23
const auto & value = expression; \
24
24
\
25
- UNIT_ASSERT_EQUAL_C (value, expected, \
25
+ UNIT_ASSERT_## op (value, expected, \
26
26
description << " mismatch, subdomain with id " << subdomain.GetDomainKey ().GetPathId () << \
27
27
" has value " << value << \
28
28
" but expected " << expected); \
29
29
}; \
30
30
}
31
31
32
+ #define DESCRIBE_ASSERT_EQUAL (name, type, expression, description ) DESCRIBE_ASSERT(EQUAL_C, name, type, expression, description)
33
+ #define DESCRIBE_ASSERT_GE (name, type, expression, description ) DESCRIBE_ASSERT(GE_C, name, type, expression, description)
34
+
32
35
33
36
void NotInSubdomain (const NKikimrScheme::TEvDescribeSchemeResult& record) {
34
37
UNIT_ASSERT (record.HasPathDescription ());
@@ -671,6 +674,7 @@ TCheckFunc PQPartitionsInsideDomain(ui64 count) {
671
674
672
675
DESCRIBE_ASSERT_EQUAL (TopicReservedStorage, ui64, subdomain.GetDiskSpaceUsage().GetTopics().GetReserveSize(), " Topic ReserveSize" )
673
676
DESCRIBE_ASSERT_EQUAL (TopicAccountSize, ui64, subdomain.GetDiskSpaceUsage().GetTopics().GetAccountSize(), " Topic AccountSize" )
677
+ DESCRIBE_ASSERT_GE (TopicAccountSizeGE, ui64, subdomain.GetDiskSpaceUsage().GetTopics().GetAccountSize(), " Topic AccountSize" )
674
678
DESCRIBE_ASSERT_EQUAL (TopicUsedReserveSize, ui64, subdomain.GetDiskSpaceUsage().GetTopics().GetUsedReserveSize(), " Topic UsedReserveSize" )
675
679
676
680
TCheckFunc PathsInsideDomainOneOf (TSet<ui64> variants) {
@@ -1185,6 +1189,8 @@ TCheckFunc ServerlessComputeResourcesMode(NKikimrSubDomains::EServerlessComputeR
1185
1189
}
1186
1190
1187
1191
#undef DESCRIBE_ASSERT_EQUAL
1192
+ #undef DESCRIBE_ASSERT_GE
1193
+ #undef DESCRIBE_ASSERT
1188
1194
1189
1195
} // NLs
1190
1196
} // NSchemeShardUT_Private
0 commit comments