Fixed add new group bug and added test coverage for group configuration