@@ -150,23 +150,25 @@ test("timestampz round trip", function() {
150
150
client . on ( 'drain' , client . end . bind ( client ) ) ;
151
151
} ) ;
152
152
153
- test ( 'early AD date' , function ( ) {
154
- var client = helper . client ( ) ;
155
- client . on ( 'error' , function ( err ) {
156
- console . log ( err ) ;
157
- client . end ( ) ;
158
- } ) ;
153
+ if ( ! helper . config . binary ) {
154
+ test ( 'early AD & BC date' , function ( ) {
155
+ var client = helper . client ( ) ;
156
+ client . on ( 'error' , function ( err ) {
157
+ console . log ( err ) ;
158
+ client . end ( ) ;
159
+ } ) ;
159
160
160
- client . query ( 'SELECT $1::TIMESTAMPTZ as when' , [ "0062-03-08 14:32:00" ] , assert . success ( function ( res ) {
161
- assert . equal ( res . rows [ 0 ] . when . getFullYear ( ) , 62 ) ;
162
- } ) )
161
+ client . query ( 'SELECT $1::TIMESTAMPTZ as when' , [ "0062-03-08 14:32:00" ] , assert . success ( function ( res ) {
162
+ assert . equal ( res . rows [ 0 ] . when . getFullYear ( ) , 62 ) ;
163
+ } ) )
163
164
164
- client . query ( 'SELECT $1::TIMESTAMPTZ as when' , [ "0062-03-08 14:32:00 BC" ] , assert . success ( function ( res ) {
165
- assert . equal ( res . rows [ 0 ] . when . getFullYear ( ) , - 62 ) ;
166
- } ) )
165
+ client . query ( 'SELECT $1::TIMESTAMPTZ as when' , [ "0062-03-08 14:32:00 BC" ] , assert . success ( function ( res ) {
166
+ assert . equal ( res . rows [ 0 ] . when . getFullYear ( ) , - 62 ) ;
167
+ } ) )
167
168
168
- client . on ( 'drain' , client . end . bind ( client ) ) ;
169
- } )
169
+ client . on ( 'drain' , client . end . bind ( client ) ) ;
170
+ } )
171
+ }
170
172
171
173
helper . pg . connect ( helper . config , assert . calls ( function ( err , client , done ) {
172
174
assert . isNull ( err ) ;
0 commit comments