@Test
  public void testBeelineAutoCommit() throws Exception {
    TestBeeline bl = new TestBeeline();
    String[] args = {};
    bl.initArgs(args);
    Assert.assertTrue(bl.getOpts().getAutoCommit());

    args = new String[] {"--autoCommit=false"};
    bl.initArgs(args);
    Assert.assertFalse(bl.getOpts().getAutoCommit());

    args = new String[] {"--autoCommit=true"};
    bl.initArgs(args);
    Assert.assertTrue(bl.getOpts().getAutoCommit());
    bl.close();
  }
Test setting hive conf and hive vars with --hiveconf and --hivevar
beeline/src/test/org/apache/hive/beeline/TestBeelineArgParsing.java