Fix up connection test, fix misnamed var