Package org.hibernate.test.connections

Source Code of org.hibernate.test.connections.BasicConnectionProviderTest

// $Id: BasicConnectionProviderTest.java 10977 2006-12-12 23:28:04Z steve.ebersole@jboss.com $
package org.hibernate.test.connections;

import junit.framework.Test;

import org.hibernate.ConnectionReleaseMode;
import org.hibernate.Session;
import org.hibernate.cfg.Configuration;
import org.hibernate.cfg.Environment;
import org.hibernate.junit.functional.FunctionalTestClassTestSuite;

/**
* Implementation of BasicConnectionProviderTest.
*
* @author Steve Ebersole
*/
public class BasicConnectionProviderTest extends ConnectionManagementTestCase {

  public BasicConnectionProviderTest(String name) {
    super( name );
  }

  public static Test suite() {
    return new FunctionalTestClassTestSuite( BasicConnectionProviderTest.class );
  }

  protected Session getSessionUnderTest() {
    return openSession();
  }

  protected void reconnect(Session session) {
    session.reconnect();
  }

  public void configure(Configuration cfg) {
    super.configure( cfg );
    cfg.setProperty( Environment.RELEASE_CONNECTIONS, ConnectionReleaseMode.ON_CLOSE.toString() );
  }
}
TOP

Related Classes of org.hibernate.test.connections.BasicConnectionProviderTest

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.