Fixed test_update_related_field_backward_m2m unit test
Unit test refactoring
Fixed a bug in resource update flow