Completed implementation of test