Fix double .connect() call in test case