Record inputRecord = (Record) inputRecordControl.getMock();
MockControl outputRecordControl = MockControl.createStrictControl(Record.class);
Record outputRecord = (Record) outputRecordControl.getMock();
MockControl connectionSpecControl = MockControl.createStrictControl(ConnectionSpec.class);
ConnectionSpec connectionSpec = (ConnectionSpec) connectionSpecControl.getMock();
MockControl interactionSpecControl = MockControl.createStrictControl(InteractionSpec.class);
InteractionSpec interactionSpec = (InteractionSpec) interactionSpecControl.getMock();
connectionFactory.getConnection(connectionSpec);
connectionFactoryControl.setReturnValue(connection, 1);