Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.hsqldb.test
Class TestSql  view TestSql download TestSql.java

java.lang.Object
  extended byjunit.framework.Assert
      extended byjunit.framework.TestCase
          extended byorg.hsqldb.test.TestSql
All Implemented Interfaces:
junit.framework.Test

public class TestSql
extends junit.framework.TestCase

Test sql statements via jdbc against in-memory database


Field Summary
(package private)  java.sql.Connection cConnection
           
(package private)  java.lang.String getColumnName
           
(package private)  java.lang.String password
           
(package private)  java.sql.Statement stmnt
           
(package private)  java.lang.String url
           
(package private)  java.lang.String user
           
 
Fields inherited from class junit.framework.TestCase
 
Constructor Summary
TestSql(java.lang.String name)
           
 
Method Summary
static void main(java.lang.String[] argv)
           
protected  void setUp()
          Sets up the fixture, for example, open a network connection.
protected  void tearDown()
          Tears down the fixture, for example, close a network connection.
 void testDoubleNaN()
          Demonstration of a reported bug.
 void testMetaData()
           
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

url

java.lang.String url

user

java.lang.String user

password

java.lang.String password

stmnt

java.sql.Statement stmnt

cConnection

java.sql.Connection cConnection

getColumnName

java.lang.String getColumnName
Constructor Detail

TestSql

public TestSql(java.lang.String name)
Method Detail

setUp

protected void setUp()
Description copied from class: junit.framework.TestCase
Sets up the fixture, for example, open a network connection. This method is called before a test is executed.


testMetaData

public void testMetaData()

testDoubleNaN

public void testDoubleNaN()
Demonstration of a reported bug.

Because all values were turned into strings with toString before PreparedStatement.executeQuery() was called, special values such as NaN were not accepted. In 1.7.0 these values are inserted as nulls (fredt) This test can be extended to cover various conversions through JDBC


tearDown

protected void tearDown()
Description copied from class: junit.framework.TestCase
Tears down the fixture, for example, close a network connection. This method is called after a test is executed.


main

public static void main(java.lang.String[] argv)