fixed integration test and retrieval of ids