Refactored the remaining backend tests.