641642643644645646647648649650651
public void testUnsetMatchColumn_Index() throws Exception { JdbcRowSet noInitalJrs = noInitalJdbcRowSet(); JdbcRowSet jrs = newJdbcRowSet(); int[] indexes = null; try { jrs.unsetMatchColumn(indexes); fail("Should throw NullPointerException"); } catch (NullPointerException e) { // expected }
649650651652653654655656657658659
// expected } indexes = new int[0]; jrs.unsetMatchColumn(indexes); indexes = new int[] { 1, 2, 3 }; try { jrs.unsetMatchColumn(indexes); fail("Should throw SQLException");
653654655656657658659660661662663
jrs.unsetMatchColumn(indexes); indexes = new int[] { 1, 2, 3 }; try { jrs.unsetMatchColumn(indexes); fail("Should throw SQLException"); } catch (SQLException e) { // expected, Columns being unset are not the same as set }
660661662663664665666667668669670
} catch (SQLException e) { // expected, Columns being unset are not the same as set } try { jrs.unsetMatchColumn(-2); fail("Should throw SQLException"); } catch (SQLException e) { // expected, Columns being unset are not the same as set }
667668669670671672673674675676677
} catch (SQLException e) { // expected, Columns being unset are not the same as set } try { jrs.unsetMatchColumn(0); fail("Should throw SQLException"); } catch (SQLException e) { // expected, Columns being unset are not the same as set }
675676677678679680681682683684685
// expected, Columns being unset are not the same as set } jrs.setMatchColumn(1); try { jrs.unsetMatchColumn(2); fail("Should throw SQLException"); } catch (SQLException e) { // expected, Columns being unset are not the same as set }
681682683684685686687688689690691
fail("Should throw SQLException"); } catch (SQLException e) { // expected, Columns being unset are not the same as set } jrs.unsetMatchColumn(1); try { indexes = jrs.getMatchColumnIndexes(); fail("Should throw SQLException"); } catch (SQLException e) {
693694695696697698699700701702703
} jrs.setMatchColumn(new int[] { 1, 2, 3 }); try { jrs.unsetMatchColumn(2); fail("Should throw SQLException"); } catch (SQLException e) { // expected, Columns being unset are not the same as set } try {
699700701702703704705706707708709
fail("Should throw SQLException"); } catch (SQLException e) { // expected, Columns being unset are not the same as set } try { jrs.unsetMatchColumn(3); fail("Should throw SQLException"); } catch (SQLException e) { // expected, Columns being unset are not the same as set }
705706707708709710711712713714715
fail("Should throw SQLException"); } catch (SQLException e) { // expected, Columns being unset are not the same as set } jrs.unsetMatchColumn(1); try { jrs.getMatchColumnIndexes(); fail("Should throw SQLException"); } catch (SQLException e) {