Finished testing the updated reference code