Collected garbage code tests and moved them to testgarbage.cpp