feat(test): minor additions
Some checks reported errors
continuous-integration/drone/push Build was killed

This commit is contained in:
light7734 2025-09-30 14:04:38 +03:30
parent 5148b8836c
commit 4976773218
Signed by: light7734
GPG key ID: 8C30176798F1A6BA

View file

@ -102,6 +102,16 @@ public:
++instance().m_total_case_count; ++instance().m_total_case_count;
} }
static void increment_matched_case_count()
{
++instance().m_matched_case_count;
}
static void increment_skipped_case_count()
{
++instance().m_skipped_case_count;
}
static void increment_passed_case_count() static void increment_passed_case_count()
{ {
++instance().m_passed_case_count; ++instance().m_passed_case_count;
@ -269,12 +279,15 @@ private:
void run_normal(std::invocable auto test) void run_normal(std::invocable auto test)
{ {
using details::Registry; using details::Registry;
Registry::increment_total_case_count();
// NOLINTNEXTLINE // NOLINTNEXTLINE
if (!std::regex_search(m_name.data(), Registry::get_case_regex())) if (!std::regex_search(m_name.data(), Registry::get_case_regex()))
{ {
Registry::increment_skipped_case_count();
return; return;
} }
Registry::increment_matched_case_count();
std::cout << "[Running-----------] --> "; std::cout << "[Running-----------] --> ";
std::cout << m_name << '\n'; std::cout << m_name << '\n';
@ -292,10 +305,11 @@ private:
{ {
throw; throw;
} }
return;
} }
Registry::increment_passed_case_count(); Registry::increment_passed_case_count();
Registry::increment_total_case_count();
std::cout << "[--------SUCCESS :D]" << "\n\n"; std::cout << "[--------SUCCESS :D]" << "\n\n";
} }