We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 757d23f commit e3ca8c8Copy full SHA for e3ca8c8
test/encoding_test.dart
@@ -183,6 +183,21 @@ void main() {
183
}
184
});
185
186
+ test('interval', () async {
187
+ await expectInverse(Duration(minutes: 15), PostgreSQLDataType.interval);
188
+ await expectInverse(
189
+ Duration(days: 1, minutes: 15), PostgreSQLDataType.interval);
190
191
+ -Duration(days: 1, seconds: 5), PostgreSQLDataType.interval);
192
+ try {
193
+ await conn.query('INSERT INTO t (v) VALUES (@v:interval)',
194
+ substitutionValues: {'v': 'not-interval'});
195
+ fail('unreachable');
196
+ } on FormatException catch (e) {
197
+ expect(e.toString(), contains('Expected: Duration'));
198
+ }
199
+ });
200
+
201
test('numeric', () async {
202
final binaries = {
203
'-123400000.20000': [
0 commit comments