Corrected test_4 implementation.