22using System . Data ;
33using System . Data . Common ;
44using System . Threading . Tasks ;
5+ using NUnit . Framework ;
6+ using Snowflake . Data . Client ;
7+ using Snowflake . Data . Core ;
8+ using Snowflake . Data . Tests . Util ;
59
610namespace Snowflake . Data . Tests . IntegrationTests
711{
8- using Snowflake . Data . Client ;
9- using Snowflake . Data . Core ;
10- using NUnit . Framework ;
11-
1212 [ TestFixture ]
1313 class SFMultiStatementsIT : SFBaseTest
1414 {
@@ -21,6 +21,7 @@ public void TestSelectWithoutBinding()
2121 {
2222 conn . ConnectionString = ConnectionString ;
2323 conn . Open ( ) ;
24+ SessionParameterAlterer . SetResultFormat ( conn , ResultFormat . JSON ) ;
2425
2526 IDbCommand cmd = conn . CreateCommand ( ) ;
2627 var param = cmd . CreateParameter ( ) ;
@@ -87,6 +88,7 @@ public async Task TestSelectAsync()
8788 {
8889 conn . ConnectionString = ConnectionString ;
8990 conn . Open ( ) ;
91+ SessionParameterAlterer . SetResultFormat ( conn , ResultFormat . JSON ) ;
9092
9193 DbCommand cmd = conn . CreateCommand ( ) ;
9294 var param = cmd . CreateParameter ( ) ;
@@ -128,6 +130,7 @@ public void TestSelectWithBinding()
128130 {
129131 conn . ConnectionString = ConnectionString ;
130132 conn . Open ( ) ;
133+ SessionParameterAlterer . SetResultFormat ( conn , ResultFormat . JSON ) ;
131134
132135 IDbCommand cmd = conn . CreateCommand ( ) ;
133136 // Set statement count
@@ -180,6 +183,8 @@ public void TestMixedQueryTypeWithBinding()
180183 {
181184 conn . ConnectionString = ConnectionString ;
182185 conn . Open ( ) ;
186+ SessionParameterAlterer . SetResultFormat ( conn , ResultFormat . JSON ) ;
187+
183188
184189 using ( DbCommand cmd = conn . CreateCommand ( ) )
185190 {
@@ -284,6 +289,7 @@ public void TestWithExecuteNonQuery()
284289 {
285290 conn . ConnectionString = ConnectionString ;
286291 conn . Open ( ) ;
292+ SessionParameterAlterer . SetResultFormat ( conn , ResultFormat . JSON ) ;
287293
288294 using ( DbCommand cmd = conn . CreateCommand ( ) )
289295 {
@@ -352,6 +358,7 @@ public void TestWithAllQueryTypes()
352358 {
353359 conn . ConnectionString = ConnectionString ;
354360 conn . Open ( ) ;
361+ SessionParameterAlterer . SetResultFormat ( conn , ResultFormat . JSON ) ;
355362
356363 using ( DbCommand cmd = conn . CreateCommand ( ) )
357364 {
@@ -452,6 +459,7 @@ public void TestWithMultipleStatementSetting()
452459 {
453460 conn . ConnectionString = ConnectionString ;
454461 conn . Open ( ) ;
462+ SessionParameterAlterer . SetResultFormat ( conn , ResultFormat . JSON ) ;
455463
456464 using ( DbCommand cmd = conn . CreateCommand ( ) )
457465 {
@@ -539,6 +547,7 @@ public void TestResultSetReturnedForAllQueryTypes()
539547 {
540548 conn . ConnectionString = ConnectionString ;
541549 conn . Open ( ) ;
550+ SessionParameterAlterer . SetResultFormat ( conn , ResultFormat . JSON ) ;
542551
543552 using ( DbCommand cmd = conn . CreateCommand ( ) )
544553 {
0 commit comments