My experience with $httpBackend with e2e tests and out of memory exceptions.
$httpBackend and out of memory exceptions
I was doing a simple $http request that would expect some JSON back. I was getting through 2.5gb of ram before my Casperjs test would fall over with out of memory exception and Phantomjs telling me how to report this bug. I followed the instructions to get an error report for Phantomjs and it was not giving me any useful information for a bug report, so it was something in my code that was the problem.
What I figured out:
Returning invalid JSON and making lots calls to the $httpBackend in quick succession then I experienced my tests falling over very quickly with out of memory exceptions. It also slows down the tests as the memory does not get released very quickly.
If you make lots of calls to $httpBackend full stop then it tends to chew through lots of memory. Use it sparingly and have your code against calling it too frequently as it is very expensive.
There is caching available for on $http requests but I have not used it yet. $http