Answer the question
In order to leave comments, you need to log in
How to check for compile-time dependent things?
Once again we are trying to start writing tests for legacy projects. At least for potentially buggy pieces.
We use GoogleTests
There is a piece of code that parses the compilation date, takes out various elements from it, such as the string writing of the month and translates it into some convenient and uniform number.
Of course, all this depends on the locale compiler and God knows what else.
Simple tests check small pieces, such as converting a month to a number.
EXPECT_EQ(rc_guisrv::utils::MonthByName("Feb"), 2);
EXPECT_EQ(rc_guisrv::utils::MonthByName("Фев"), 2);
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question