Use expectAssertion instead of manual assert stubbing
Remove a .swp file
Introduce expectDeprecation. Remove TESTING_DEPRECATION.