[CHORE] Split error and success callback functions to be
available on the scope for testing purposes
[TEST] Add partial spec to test ajax callbacks of reset_paths