| 7 | namespace platform::tests_support |
| 8 | { |
| 9 | time_t GetUnixtimeByDate(uint16_t year, Month month, uint8_t monthDay, uint8_t hours, uint8_t minutes) |
| 10 | { |
| 11 | std::tm t{}; |
| 12 | t.tm_year = year - 1900; |
| 13 | t.tm_mon = static_cast<int>(month) - 1; |
| 14 | t.tm_mday = monthDay; |
| 15 | t.tm_hour = hours; |
| 16 | t.tm_min = minutes; |
| 17 | return std::mktime(&t); |
| 18 | } |
| 19 | |
| 20 | time_t GetUnixtimeByWeekday(uint16_t year, Month month, Weekday weekday, uint8_t hours, uint8_t minutes) |
| 21 | { |
no outgoing calls