Binders { public static Binder stringBinder() { return STRING_BINDER; } private  Binders(); static Binder defaultBinder(); static Binder stringBinder(); static Binder dateBinder(); static Binder timestampBinder(); static Binder timeBinder(); static Binder decimalBinder(); static Binder integerBinder();  }
@Test public void stringBinderBindsString() throws SQLException { Binder binder = Binders.stringBinder(); binder.bind(stmt, 1, "hello"); verify(stmt).setString(1, "hello"); }
@Test public void stringBinderBindsEnum() throws SQLException { Binder binder = Binders.stringBinder(); binder.bind(stmt, 1, TestEnum.BAR); verify(stmt).setString(1, "BAR"); }
@Test public void stringBinderBindsObject() throws SQLException { Binder binder = Binders.stringBinder(); binder.bind(stmt, 1, new Foo()); verify(stmt).setString(1, "foo"); }
@Test public void stringBinderBindsNull() throws SQLException { Binder binder = Binders.stringBinder(); binder.bind(stmt, 1, null); verify(stmt).setObject(1, null); }