def METHOD_NAME(self, top):
    attrs = set(self.expected_attrs
                + self.guessed_attrs
                + mandatory_attrs
                + ['indices', 'resindices', 'segindices'])
    for attr in top.attrs:
        assert attr.attrname in attrs, 'Unexpected attribute: {}'.format(attr.attrname)