[lang-ref] ( get_today ) ( python )
def test_get_today():
# datetime.date.today()
p = subprocess.Popen(['date', r'+%Y/%m/%d'], stdout=subprocess.PIPE, text=True, encoding='utf-8')
stdout, _ = p.communicate()
expected = stdout.rstrip()
d = datetime.date.today()
actual = d.strftime(r'%Y/%m/%d')
assert expected == actual