Some equality tests

@alazier @kspangsege