@@ -61,7 +61,7 @@ public void shouldToQuerySimpleSelectWithoutBindings() {
61
61
assertThat (select .getSource ()).isInstanceOf (Select .class );
62
62
assertThat (select .toQuery ()).isEqualTo ("SELECT foo.bar, foo.baz FROM foo" );
63
63
64
- select .bind (connectionMock );
64
+ select .createBoundStatement (connectionMock );
65
65
66
66
verifyZeroInteractions (statementMock );
67
67
}
@@ -76,7 +76,7 @@ public void shouldToQuerySimpleSelectWithSimpleFilter() {
76
76
assertThat (select .getSource ()).isInstanceOf (Select .class );
77
77
assertThat (select .toQuery ()).isEqualTo ("SELECT foo.bar, foo.baz FROM foo WHERE foo.doe = $1" );
78
78
79
- select .bind (connectionMock );
79
+ select .createBoundStatement (connectionMock );
80
80
81
81
verify (statementMock ).bind (0 , "John" );
82
82
verifyNoMoreInteractions (statementMock );
@@ -93,7 +93,7 @@ public void shouldToQuerySimpleSelectWithMultipleFilters() {
93
93
assertThat (select .getSource ()).isInstanceOf (Select .class );
94
94
assertThat (select .toQuery ()).isEqualTo ("SELECT foo.bar, foo.baz FROM foo WHERE foo.doe = $1 AND foo.baz = $2" );
95
95
96
- select .bind (connectionMock );
96
+ select .createBoundStatement (connectionMock );
97
97
98
98
verify (statementMock ).bind (0 , "John" );
99
99
verify (statementMock ).bind (1 , "Jake" );
@@ -110,7 +110,7 @@ public void shouldToQuerySimpleSelectWithNullFilter() {
110
110
assertThat (select .getSource ()).isInstanceOf (Select .class );
111
111
assertThat (select .toQuery ()).isEqualTo ("SELECT foo.bar, foo.baz FROM foo WHERE foo.doe IS NULL" );
112
112
113
- select .bind (connectionMock );
113
+ select .createBoundStatement (connectionMock );
114
114
verifyZeroInteractions (statementMock );
115
115
}
116
116
@@ -124,7 +124,7 @@ public void shouldToQuerySimpleSelectWithIterableFilter() {
124
124
assertThat (select .getSource ()).isInstanceOf (Select .class );
125
125
assertThat (select .toQuery ()).isEqualTo ("SELECT foo.bar, foo.baz FROM foo WHERE foo.doe IN ($1, $2)" );
126
126
127
- select .bind (connectionMock );
127
+ select .createBoundStatement (connectionMock );
128
128
verify (statementMock ).bind (0 , "John" );
129
129
verify (statementMock ).bind (1 , "Jake" );
130
130
verifyNoMoreInteractions (statementMock );
@@ -147,7 +147,7 @@ public void shouldToQuerySimpleInsert() {
147
147
assertThat (insert .getSource ()).isInstanceOf (Insert .class );
148
148
assertThat (insert .toQuery ()).isEqualTo ("INSERT INTO foo (bar) VALUES ($1)" );
149
149
150
- insert .bind (connectionMock );
150
+ insert .createBoundStatement (connectionMock );
151
151
verify (statementMock ).bind (0 , "Foo" );
152
152
verify (statementMock ).returnGeneratedValues (any (String [].class ));
153
153
verifyNoMoreInteractions (statementMock );
@@ -170,7 +170,7 @@ public void shouldToQuerySimpleUpdate() {
170
170
assertThat (update .getSource ()).isInstanceOf (Update .class );
171
171
assertThat (update .toQuery ()).isEqualTo ("UPDATE foo SET bar = $1" );
172
172
173
- update .bind (connectionMock );
173
+ update .createBoundStatement (connectionMock );
174
174
verify (statementMock ).bind (0 , "Foo" );
175
175
verifyNoMoreInteractions (statementMock );
176
176
}
@@ -185,7 +185,7 @@ public void shouldToQueryNullUpdate() {
185
185
assertThat (update .getSource ()).isInstanceOf (Update .class );
186
186
assertThat (update .toQuery ()).isEqualTo ("UPDATE foo SET bar = $1" );
187
187
188
- update .bind (connectionMock );
188
+ update .createBoundStatement (connectionMock );
189
189
verify (statementMock ).bindNull (0 , String .class );
190
190
191
191
verifyNoMoreInteractions (statementMock );
@@ -202,7 +202,7 @@ public void shouldToQueryUpdateWithFilter() {
202
202
assertThat (update .getSource ()).isInstanceOf (Update .class );
203
203
assertThat (update .toQuery ()).isEqualTo ("UPDATE foo SET bar = $1 WHERE foo.baz = $2" );
204
204
205
- update .bind (connectionMock );
205
+ update .createBoundStatement (connectionMock );
206
206
verify (statementMock ).bind (0 , "Foo" );
207
207
verify (statementMock ).bind (1 , "Baz" );
208
208
verifyNoMoreInteractions (statementMock );
@@ -218,7 +218,7 @@ public void shouldToQuerySimpleDeleteWithSimpleFilter() {
218
218
assertThat (delete .getSource ()).isInstanceOf (Delete .class );
219
219
assertThat (delete .toQuery ()).isEqualTo ("DELETE FROM foo WHERE foo.doe = $1" );
220
220
221
- delete .bind (connectionMock );
221
+ delete .createBoundStatement (connectionMock );
222
222
verify (statementMock ).bind (0 , "John" );
223
223
verifyNoMoreInteractions (statementMock );
224
224
}
@@ -234,7 +234,7 @@ public void shouldToQuerySimpleDeleteWithMultipleFilters() {
234
234
assertThat (delete .getSource ()).isInstanceOf (Delete .class );
235
235
assertThat (delete .toQuery ()).isEqualTo ("DELETE FROM foo WHERE foo.doe = $1 AND foo.baz = $2" );
236
236
237
- delete .bind (connectionMock );
237
+ delete .createBoundStatement (connectionMock );
238
238
verify (statementMock ).bind (0 , "John" );
239
239
verify (statementMock ).bind (1 , "Jake" );
240
240
verifyNoMoreInteractions (statementMock );
@@ -250,7 +250,7 @@ public void shouldToQuerySimpleDeleteWithNullFilter() {
250
250
assertThat (delete .getSource ()).isInstanceOf (Delete .class );
251
251
assertThat (delete .toQuery ()).isEqualTo ("DELETE FROM foo WHERE foo.doe IS NULL" );
252
252
253
- delete .bind (connectionMock );
253
+ delete .createBoundStatement (connectionMock );
254
254
verifyZeroInteractions (statementMock );
255
255
}
256
256
}
0 commit comments