Add tests for operator/()

This commit is contained in:
Howard Hinnant committed 2015-08-14 19:17:12 -04:00
1 parent 27ebc9dc44
commit 12e6d38bba
23 files changed
+730

No files matched your search

@@ -147,13 +147,17 @@ main()
using namespace date;
constexpr year_month_weekday ymdl1 = {2015_y, aug, weekday_indexed{fri, 2}};
#if __cplusplus >= 201402
static_assert(ymdl1.ok(), "");
#endif
static_assert(ymdl1.year() == 2015_y, "");
static_assert(ymdl1.month() == aug, "");
static_assert(ymdl1.weekday_indexed() == fri[2], "");
#if __cplusplus >= 201402
constexpr day_point dp = ymdl1;
constexpr year_month_day ymd = dp;
static_assert(ymd == 2015_y/aug/14, "");
#endif
constexpr year_month_weekday ymdl2 = sat[1]/aug/2015;