Refactored container test code to get rid of unnecessary function argument.
Maintained some test routines (setMemoryTest)