### Question:
TableQuery extends AbstractTransactionalQuery implements
        QueryDelegate, QueryDelegate.RowIdChangeNotifier { @Override public void commit() throws UnsupportedOperationException, SQLException { getLogger().log(Level.FINE, "DB -> commit"); super.commit(); RowIdChangeEvent[] unFiredEvents = bufferedEvents .toArray(new RowIdChangeEvent[] {}); bufferedEvents.clear(); if (rowIdChangeListeners != null && !rowIdChangeListeners.isEmpty()) { for (RowIdChangeListener r : rowIdChangeListeners) { for (RowIdChangeEvent e : unFiredEvents) { r.rowIdChange(e); } } } } TableQuery(String tableName, JDBCConnectionPool connectionPool,
            SQLGenerator sqlGenerator);  TableQuery(String catalogName, String schemaName, String tableName,
            JDBCConnectionPool connectionPool, SQLGenerator sqlGenerator);  TableQuery(String tableName, JDBCConnectionPool connectionPool); protected  TableQuery(String catalogName, String schemaName,
            String tableName, JDBCConnectionPool connectionPool,
            SQLGenerator sqlGenerator, boolean escapeNames); @Override int getCount(); @Override ResultSet getResults(int offset, int pagelength); @Override boolean implementationRespectsPagingLimits(); @Override int storeRow(RowItem row); RowId storeRowImmediately(RowItem row); @Override void setFilters(List<Filter> filters); @Override void setOrderBy(List<OrderBy> orderBys); @Override void beginTransaction(); @Override void commit(); @Override void rollback(); @Override List<String> getPrimaryKeyColumns(); String getVersionColumn(); void setVersionColumn(String column); String getTableName(); String getCatalogName(); String getSchemaName(); SQLGenerator getSqlGenerator(); @Override boolean removeRow(RowItem row); @Override boolean containsRowWithKey(Object... keys); @Override void addRowIdChangeListener(RowIdChangeListener listener); @Override void removeRowIdChangeListener(RowIdChangeListener listener);  }### Answer:
@Test(expected = SQLException.class) public void commit_noActiveTransaction_shouldFail() throws SQLException { TableQuery tQuery = new TableQuery("people", connectionPool, SQLTestsConstants.sqlGen); tQuery.commit(); }