Define equality
Add groups and group_ids accessor. Replace group_name with primary_group

#groups and #group_ids remain untested and unfortunately make use of
the module's top-level interface