Use a factory to create adapters for testing