public class DateCriteriaTest extends TestCase {
public void testCriteria() throws Exception {
DateCriteria criteria = new DateCriteria("timestamp_before", "TIMESTAMP");
Criteria value = criteria.parseValue("1307570400000")[0];
assertEquals("TIMESTAMP < :timestamp_before", value.getFilterClause().toString());
criteria = new DateCriteria("timestamp_after", "TIMESTAMP");
value = criteria.parseValue("1307570400000")[0];
assertEquals("TIMESTAMP > :timestamp_after", value.getFilterClause().toString());
criteria = new DateCriteria("timestamp", "TIMESTAMP");
value = criteria.parseValue("1307570400000")[0];
assertEquals("TIMESTAMP = :timestamp", value.getFilterClause().toString());
}