Add test to change group in related objects.

Change-Id: I9ed81fdd7f222dc79b0e4e7b92caabcbc1d7e407