use of org.apache.cayenne.test.jdbc.TableHelper in project cayenne by apache.
the class DataContextNoPkIT method setUp.
@Before
public void setUp() throws Exception {
TableHelper noPkTestTable = new TableHelper(dbHelper, "NO_PK_TEST", "ATTRIBUTE1");
noPkTestTable.deleteAll();
noPkTestTable.insert(1);
noPkTestTable.insert(2);
}
use of org.apache.cayenne.test.jdbc.TableHelper in project cayenne by apache.
the class DataContextObjectTrackingIT method setUp.
@Before
public void setUp() throws Exception {
tArtist = new TableHelper(dbHelper, "ARTIST");
tArtist.setColumns("ARTIST_ID", "ARTIST_NAME");
tPainting = new TableHelper(dbHelper, "PAINTING");
tPainting.setColumns("PAINTING_ID", "ARTIST_ID", "PAINTING_TITLE", "ESTIMATED_PRICE").setColumnTypes(Types.INTEGER, Types.BIGINT, Types.VARCHAR, Types.DECIMAL);
}
use of org.apache.cayenne.test.jdbc.TableHelper in project cayenne by apache.
the class DataContextOuterJoinsIT method setUp.
@Before
public void setUp() throws Exception {
artistHelper = new TableHelper(dbHelper, "ARTIST", "ARTIST_ID", "ARTIST_NAME");
paintingHelper = new TableHelper(dbHelper, "PAINTING", "PAINTING_ID", "ARTIST_ID", "PAINTING_TITLE").setColumnTypes(Types.INTEGER, Types.BIGINT, Types.VARCHAR);
artgroupHelper = new TableHelper(dbHelper, "ARTGROUP", "GROUP_ID", "NAME");
artistGroupHelper = new TableHelper(dbHelper, "ARTIST_GROUP", "GROUP_ID", "ARTIST_ID");
}
use of org.apache.cayenne.test.jdbc.TableHelper in project cayenne by apache.
the class DataContextPerformQueryAPIIT method setUp.
@Before
public void setUp() throws Exception {
tArtist = new TableHelper(dbHelper, "ARTIST");
tArtist.setColumns("ARTIST_ID", "ARTIST_NAME");
tPainting = new TableHelper(dbHelper, "PAINTING");
tPainting.setColumns("PAINTING_ID", "ARTIST_ID", "PAINTING_TITLE", "ESTIMATED_PRICE").setColumnTypes(Types.INTEGER, Types.BIGINT, Types.VARCHAR, Types.DECIMAL);
}
use of org.apache.cayenne.test.jdbc.TableHelper in project cayenne by apache.
the class DataContextPrefetchExtras1IT method createDataSet.
protected void createDataSet() throws Exception {
TableHelper tPainting = new TableHelper(dbHelper, "PAINTING");
tPainting.setColumns("PAINTING_ID", "PAINTING_TITLE");
TableHelper tPaintingInfo = new TableHelper(dbHelper, "PAINTING_INFO");
tPaintingInfo.setColumns("PAINTING_ID", "TEXT_REVIEW");
for (int i = 1; i <= 10; i++) {
tPainting.insert(i, "P" + i);
tPaintingInfo.insert(i, "Review #" + i);
}
}
Aggregations