def test_compound_is_empty(): element = DateYYYYMMDD() assert element.is_empty element.find_one(u'year').set(1979) assert not element.is_empty