Bugfix for Ri(q) groups + add test