Fixed bug when specifying a connection object with regression test.