Search in sources :

Example 1 with SuperHero

use of util.SuperHero in project jdk8u_jdk by JetBrains.

the class SQLInputImplTests method setUpMethod.

@BeforeMethod
@Override
public void setUpMethod() throws Exception {
    map = new HashMap<>();
    impl = new TestSQLDataImpl("TestSQLData");
    typeValues = Arrays.copyOf(TestSQLDataImpl.attributes, TestSQLDataImpl.attributes.length);
    hero = new SuperHero(sqlType, "Bruce", "Wayne", 1939, "Batman");
}
Also used : TestSQLDataImpl(util.TestSQLDataImpl) SuperHero(util.SuperHero) BeforeMethod(org.testng.annotations.BeforeMethod)

Example 2 with SuperHero

use of util.SuperHero in project jdk8u_jdk by JetBrains.

the class SQLOutputImplTests method setUpMethod.

@BeforeMethod
@Override
public void setUpMethod() throws Exception {
    results = new Vector();
    impl = new TestSQLDataImpl("TestSQLData");
    typeValues = Arrays.copyOf(TestSQLDataImpl.attributes, TestSQLDataImpl.attributes.length);
    hero = new SuperHero(sqlType, "Bruce", "Wayne", 1939, "Batman");
    outImpl = new SQLOutputImpl(results, map);
}
Also used : TestSQLDataImpl(util.TestSQLDataImpl) SuperHero(util.SuperHero) SQLOutputImpl(javax.sql.rowset.serial.SQLOutputImpl) Vector(java.util.Vector) BeforeMethod(org.testng.annotations.BeforeMethod)

Example 3 with SuperHero

use of util.SuperHero in project jdk8u_jdk by JetBrains.

the class SerialRefTests method test06.

/*
     * Validate that setObject() can be used to change the value of the object
     * pointed to by the SerialRef
     */
@Test
public void test06() throws Exception {
    SerialRef sr = new SerialRef(ref);
    assertTrue(hero.equals(sr.getObject()));
    SuperHero h = new SuperHero(sqlType, "Dick", "Grayson", 1940, "Robin");
    sr.setObject(h);
    assertFalse(hero.equals(sr.getObject()));
}
Also used : SuperHero(util.SuperHero) SerialRef(javax.sql.rowset.serial.SerialRef) Test(org.testng.annotations.Test) BaseTest(util.BaseTest)

Example 4 with SuperHero

use of util.SuperHero in project jdk8u_jdk by JetBrains.

the class SerialRefTests method setUpMethod.

@BeforeMethod
public void setUpMethod() throws Exception {
    map.put(sqlType, Class.forName("util.SuperHero"));
    hero = new SuperHero(sqlType, "Bruce", "Wayne", 1939, "Batman");
    ref = new StubRef(sqlType, hero);
}
Also used : SuperHero(util.SuperHero) StubRef(util.StubRef) BeforeMethod(org.testng.annotations.BeforeMethod)

Example 5 with SuperHero

use of util.SuperHero in project jdk8u_jdk by JetBrains.

the class SerialStructTests method setUpMethod.

@BeforeMethod
public void setUpMethod() throws Exception {
    attributes = new Object[] { "Bruce", "Wayne", 1939, "Batman" };
    map.put(sqlType, Class.forName("util.SuperHero"));
    struct = new StubStruct(sqlType, attributes);
    hero = new SuperHero(sqlType, "Bruce", "Wayne", 1939, "Batman");
}
Also used : SuperHero(util.SuperHero) StubStruct(util.StubStruct) BeforeMethod(org.testng.annotations.BeforeMethod)

Aggregations

SuperHero (util.SuperHero)5 BeforeMethod (org.testng.annotations.BeforeMethod)4 TestSQLDataImpl (util.TestSQLDataImpl)2 Vector (java.util.Vector)1 SQLOutputImpl (javax.sql.rowset.serial.SQLOutputImpl)1 SerialRef (javax.sql.rowset.serial.SerialRef)1 Test (org.testng.annotations.Test)1 BaseTest (util.BaseTest)1 StubRef (util.StubRef)1 StubStruct (util.StubStruct)1