org.hsqldb.test
Class TestSql
- java.lang.Object
-
- junit.framework.Assert
-
- junit.framework.TestCase
-
- org.hsqldb.test.TestBase
-
- org.hsqldb.test.TestSql
-
- All Implemented Interfaces:
- junit.framework.Test
public class TestSql extends TestBase
Test sql statements via jdbc against in-memory database
-
-
Constructor Summary
Constructors Constructor and Description TestSql(java.lang.String name)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description static voidmain(java.lang.String[] argv)voidtestAny()voidtestBinaryFunction()voidtestBinds()Fix for bug #1201135voidtestDoubleNaN()Demonstration of a reported bug.voidtestMetaData()voidtestPreparedWithManyParams()voidtestUnionColumnTypes()In 1.8.0.2, this fails in client / server due to column type of the second select for b1 being boolean, while the first select is interpreted as varchar.voidtestUnionSubquery()voidtestX1()-
Methods inherited from class org.hsqldb.test.TestBase
runWithResult, runWithResult
-
Methods inherited from class junit.framework.TestCase
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, countTestCases, fail, fail, failNotEquals, failNotSame, failSame, format, getName, run, run, runBare, setName, toString
-
-
-
-
Method Detail
-
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. This test can be extended to cover various conversions through JDBC
-
testAny
public void testAny()
-
testBinds
public void testBinds()
Fix for bug #1201135
-
testX1
public void testX1()
-
testUnionColumnTypes
public void testUnionColumnTypes()
In 1.8.0.2, this fails in client / server due to column type of the second select for b1 being boolean, while the first select is interpreted as varchar. The rowOutputBase class attempts to cast the Java Boolean into String.
-
testUnionSubquery
public void testUnionSubquery() throws java.lang.Exception- Throws:
java.lang.Exception
-
testPreparedWithManyParams
public void testPreparedWithManyParams() throws java.lang.Exception- Throws:
java.lang.Exception
-
testBinaryFunction
public void testBinaryFunction() throws java.lang.Exception- Throws:
java.lang.Exception
-
main
public static void main(java.lang.String[] argv)
-
-
DataMelt 3.0 © DataMelt by jWork.ORG