tests: enforced a full GC cycle in two test cases that may confuse leak testing due to GC latencies.