added tests

This commit is contained in:
Timo Westkämper 2010-05-24 18:37:18 +00:00
parent ee8e34fa6d
commit dacffa1e82

View File

@ -0,0 +1,26 @@
package com.mysema.query.sql.oracle;
import static org.junit.Assert.*;
import org.junit.Test;
import com.mysema.query.types.path.PNumber;
public class OracleGrammarTest {
@Test
public void constants(){
assertNotNull(OracleGrammar.level);
assertNotNull(OracleGrammar.rownum);
assertNotNull(OracleGrammar.sysdate);
}
@Test
public void sumOver(){
PNumber<Integer> intPath = new PNumber<Integer>(Integer.class, "intPath");
SumOver<Integer> sumOver = OracleGrammar.sumOver(intPath).order(intPath).partition(intPath);
assertEquals("sum(intPath) over (partition by intPath order by intPath)", sumOver.toString());
}
}