@@ -25,6 +25,7 @@ t.test('open connection and retrieves standard pg tables', async t => {
25
25
const connector = new Connector ( ) ;
26
26
const clientOpts = await connector . getOptions ( {
27
27
instanceConnectionName : String ( process . env . POSTGRES_CONNECTION_NAME ) ,
28
+ ipType : process . env . IP_TYPE || IpAddressTypes . PUBLIC ,
28
29
} ) ;
29
30
const client = new Client ( {
30
31
...clientOpts ,
@@ -53,7 +54,7 @@ t.test('open IAM connection and retrieves standard pg tables', async t => {
53
54
const connector = new Connector ( ) ;
54
55
const clientOpts = await connector . getOptions ( {
55
56
instanceConnectionName : String ( process . env . POSTGRES_CONNECTION_NAME ) ,
56
- ipType : IpAddressTypes . PUBLIC ,
57
+ ipType : process . env . IP_TYPE || IpAddressTypes . PUBLIC ,
57
58
authType : AuthTypes . IAM ,
58
59
} ) ;
59
60
const client = new Client ( {
@@ -83,6 +84,7 @@ t.test(
83
84
const connector = new Connector ( ) ;
84
85
const clientOpts = await connector . getOptions ( {
85
86
instanceConnectionName : String ( process . env . POSTGRES_CAS_CONNECTION_NAME ) ,
87
+ ipType : process . env . IP_TYPE || IpAddressTypes . PUBLIC ,
86
88
} ) ;
87
89
const client = new Client ( {
88
90
...clientOpts ,
@@ -116,6 +118,7 @@ t.test(
116
118
instanceConnectionName : String (
117
119
process . env . POSTGRES_CUSTOMER_CAS_CONNECTION_NAME
118
120
) ,
121
+ ipType : process . env . IP_TYPE || IpAddressTypes . PUBLIC ,
119
122
} ) ;
120
123
const client = new Client ( {
121
124
...clientOpts ,
@@ -146,6 +149,7 @@ t.test(
146
149
const connector = new Connector ( ) ;
147
150
const clientOpts = await connector . getOptions ( {
148
151
domainName : String ( process . env . POSTGRES_CUSTOMER_CAS_DOMAIN_NAME ) ,
152
+ ipType : process . env . IP_TYPE || IpAddressTypes . PUBLIC ,
149
153
} ) ;
150
154
const client = new Client ( {
151
155
...clientOpts ,
@@ -176,6 +180,7 @@ t.test(
176
180
const connector = new Connector ( ) ;
177
181
const clientOpts = await connector . getOptions ( {
178
182
domainName : String ( process . env . POSTGRES_CUSTOMER_CAS_INVALID_DOMAIN_NAME ) ,
183
+ ipType : process . env . IP_TYPE || IpAddressTypes . PUBLIC ,
179
184
} ) ;
180
185
const client = new Client ( {
181
186
...clientOpts ,
0 commit comments