Changes to lookup query to address test failures
Submitting first batch of unit tests