aboutsummaryrefslogtreecommitdiff
path: root/qt/sqlite/date-time/test.hxx
diff options
context:
space:
mode:
authorConstantin Michael <constantin@codesynthesis.com>2011-04-12 15:48:17 +0200
committerConstantin Michael <constantin@codesynthesis.com>2011-04-22 18:52:23 +0200
commitda9dd6be1b0203c496af4aff16df60fedc64463a (patch)
tree9b6a7c4a8dadc65af4fb1b62fcb0d0866cd4a951 /qt/sqlite/date-time/test.hxx
parentb5bdf60e53648972a5bc9c1d7b37be7dda026509 (diff)
Add UNIX time tests for qt/date-time SQLite implementation
Diffstat (limited to 'qt/sqlite/date-time/test.hxx')
-rw-r--r--qt/sqlite/date-time/test.hxx15
1 files changed, 10 insertions, 5 deletions
diff --git a/qt/sqlite/date-time/test.hxx b/qt/sqlite/date-time/test.hxx
index 27ba341..0a140b7 100644
--- a/qt/sqlite/date-time/test.hxx
+++ b/qt/sqlite/date-time/test.hxx
@@ -21,10 +21,11 @@ struct object
return
id == x.id &&
date == x.date &&
- julian_day == x.julian_day &&
+ unix_day == x.unix_day &&
time == x.time &&
seconds == x.seconds &&
- date_time == x.date_time;
+ date_time == x.date_time &&
+ unix_time == x.unix_time;
}
bool
@@ -32,10 +33,11 @@ struct object
{
return
date.isNull () &&
- julian_day.isNull () &&
+ unix_day.isNull () &&
time.isNull () &&
seconds.isNull () &&
- date_time.isNull ();
+ date_time.isNull () &&
+ unix_time.isNull ();
}
#pragma db id auto
@@ -44,7 +46,7 @@ struct object
QDate date;
#pragma db type ("INTEGER")
- QDate julian_day;
+ QDate unix_day;
QTime time;
@@ -52,6 +54,9 @@ struct object
QTime seconds;
QDateTime date_time;
+
+ #pragma db type ("INTEGER")
+ QDateTime unix_time;
};
#endif // TEST_HXX