@@ -65,9 +65,9 @@ func TestConnSuccessfully(t *testing.T) {
65
65
defer connPool .Close ()
66
66
67
67
args := test_helpers.CheckStatusesArgs {
68
- ConnPool : connPool ,
69
- Mode : connection_pool .ANY ,
70
- Servers : []string {server },
68
+ ConnPool : connPool ,
69
+ Mode : connection_pool .ANY ,
70
+ Servers : []string {server },
71
71
ExpectedPoolStatus : true ,
72
72
ExpectedStatuses : map [string ]bool {
73
73
server : true ,
@@ -90,9 +90,9 @@ func TestReconnect(t *testing.T) {
90
90
test_helpers .StopTarantoolWithCleanup (instances [0 ])
91
91
92
92
args := test_helpers.CheckStatusesArgs {
93
- ConnPool : connPool ,
94
- Mode : connection_pool .ANY ,
95
- Servers : []string {server },
93
+ ConnPool : connPool ,
94
+ Mode : connection_pool .ANY ,
95
+ Servers : []string {server },
96
96
ExpectedPoolStatus : true ,
97
97
ExpectedStatuses : map [string ]bool {
98
98
server : false ,
@@ -106,9 +106,9 @@ func TestReconnect(t *testing.T) {
106
106
require .Nilf (t , err , "failed to restart tarantool" )
107
107
108
108
args = test_helpers.CheckStatusesArgs {
109
- ConnPool : connPool ,
110
- Mode : connection_pool .ANY ,
111
- Servers : []string {server },
109
+ ConnPool : connPool ,
110
+ Mode : connection_pool .ANY ,
111
+ Servers : []string {server },
112
112
ExpectedPoolStatus : true ,
113
113
ExpectedStatuses : map [string ]bool {
114
114
server : true ,
@@ -133,9 +133,9 @@ func TestDisconnectAll(t *testing.T) {
133
133
test_helpers .StopTarantoolWithCleanup (instances [1 ])
134
134
135
135
args := test_helpers.CheckStatusesArgs {
136
- ConnPool : connPool ,
137
- Mode : connection_pool .ANY ,
138
- Servers : []string {server1 , server2 },
136
+ ConnPool : connPool ,
137
+ Mode : connection_pool .ANY ,
138
+ Servers : []string {server1 , server2 },
139
139
ExpectedPoolStatus : false ,
140
140
ExpectedStatuses : map [string ]bool {
141
141
server1 : false ,
@@ -153,9 +153,9 @@ func TestDisconnectAll(t *testing.T) {
153
153
require .Nilf (t , err , "failed to restart tarantool" )
154
154
155
155
args = test_helpers.CheckStatusesArgs {
156
- ConnPool : connPool ,
157
- Mode : connection_pool .ANY ,
158
- Servers : []string {server1 , server2 },
156
+ ConnPool : connPool ,
157
+ Mode : connection_pool .ANY ,
158
+ Servers : []string {server1 , server2 },
159
159
ExpectedPoolStatus : true ,
160
160
ExpectedStatuses : map [string ]bool {
161
161
server1 : true ,
@@ -176,9 +176,9 @@ func TestClose(t *testing.T) {
176
176
require .NotNilf (t , connPool , "conn is nil after Connect" )
177
177
178
178
args := test_helpers.CheckStatusesArgs {
179
- ConnPool : connPool ,
180
- Mode : connection_pool .ANY ,
181
- Servers : []string {server1 , server2 },
179
+ ConnPool : connPool ,
180
+ Mode : connection_pool .ANY ,
181
+ Servers : []string {server1 , server2 },
182
182
ExpectedPoolStatus : true ,
183
183
ExpectedStatuses : map [string ]bool {
184
184
server1 : true ,
@@ -192,9 +192,9 @@ func TestClose(t *testing.T) {
192
192
connPool .Close ()
193
193
194
194
args = test_helpers.CheckStatusesArgs {
195
- ConnPool : connPool ,
196
- Mode : connection_pool .ANY ,
197
- Servers : []string {server1 , server2 },
195
+ ConnPool : connPool ,
196
+ Mode : connection_pool .ANY ,
197
+ Servers : []string {server1 , server2 },
198
198
ExpectedPoolStatus : false ,
199
199
ExpectedStatuses : map [string ]bool {
200
200
server1 : false ,
@@ -353,8 +353,8 @@ func TestRoundRobinStrategy(t *testing.T) {
353
353
args := test_helpers.ListenOnInstanceArgs {
354
354
ServersNumber : serversNumber ,
355
355
ExpectedPorts : allPorts ,
356
- ConnPool : connPool ,
357
- Mode : connection_pool .ANY ,
356
+ ConnPool : connPool ,
357
+ Mode : connection_pool .ANY ,
358
358
}
359
359
360
360
err = test_helpers .ProcessListenOnInstance (args )
@@ -364,8 +364,8 @@ func TestRoundRobinStrategy(t *testing.T) {
364
364
args = test_helpers.ListenOnInstanceArgs {
365
365
ServersNumber : serversNumber ,
366
366
ExpectedPorts : masterPorts ,
367
- ConnPool : connPool ,
368
- Mode : connection_pool .RW ,
367
+ ConnPool : connPool ,
368
+ Mode : connection_pool .RW ,
369
369
}
370
370
371
371
err = test_helpers .ProcessListenOnInstance (args )
@@ -375,8 +375,8 @@ func TestRoundRobinStrategy(t *testing.T) {
375
375
args = test_helpers.ListenOnInstanceArgs {
376
376
ServersNumber : serversNumber ,
377
377
ExpectedPorts : replicaPorts ,
378
- ConnPool : connPool ,
379
- Mode : connection_pool .RO ,
378
+ ConnPool : connPool ,
379
+ Mode : connection_pool .RO ,
380
380
}
381
381
382
382
err = test_helpers .ProcessListenOnInstance (args )
@@ -386,8 +386,8 @@ func TestRoundRobinStrategy(t *testing.T) {
386
386
args = test_helpers.ListenOnInstanceArgs {
387
387
ServersNumber : serversNumber ,
388
388
ExpectedPorts : masterPorts ,
389
- ConnPool : connPool ,
390
- Mode : connection_pool .PreferRW ,
389
+ ConnPool : connPool ,
390
+ Mode : connection_pool .PreferRW ,
391
391
}
392
392
393
393
err = test_helpers .ProcessListenOnInstance (args )
@@ -397,8 +397,8 @@ func TestRoundRobinStrategy(t *testing.T) {
397
397
args = test_helpers.ListenOnInstanceArgs {
398
398
ServersNumber : serversNumber ,
399
399
ExpectedPorts : replicaPorts ,
400
- ConnPool : connPool ,
401
- Mode : connection_pool .PreferRO ,
400
+ ConnPool : connPool ,
401
+ Mode : connection_pool .PreferRO ,
402
402
}
403
403
404
404
err = test_helpers .ProcessListenOnInstance (args )
@@ -435,8 +435,8 @@ func TestRoundRobinStrategy_NoReplica(t *testing.T) {
435
435
args := test_helpers.ListenOnInstanceArgs {
436
436
ServersNumber : serversNumber ,
437
437
ExpectedPorts : allPorts ,
438
- ConnPool : connPool ,
439
- Mode : connection_pool .ANY ,
438
+ ConnPool : connPool ,
439
+ Mode : connection_pool .ANY ,
440
440
}
441
441
442
442
err = test_helpers .ProcessListenOnInstance (args )
@@ -446,8 +446,8 @@ func TestRoundRobinStrategy_NoReplica(t *testing.T) {
446
446
args = test_helpers.ListenOnInstanceArgs {
447
447
ServersNumber : serversNumber ,
448
448
ExpectedPorts : allPorts ,
449
- ConnPool : connPool ,
450
- Mode : connection_pool .RW ,
449
+ ConnPool : connPool ,
450
+ Mode : connection_pool .RW ,
451
451
}
452
452
453
453
err = test_helpers .ProcessListenOnInstance (args )
@@ -457,8 +457,8 @@ func TestRoundRobinStrategy_NoReplica(t *testing.T) {
457
457
args = test_helpers.ListenOnInstanceArgs {
458
458
ServersNumber : serversNumber ,
459
459
ExpectedPorts : allPorts ,
460
- ConnPool : connPool ,
461
- Mode : connection_pool .PreferRW ,
460
+ ConnPool : connPool ,
461
+ Mode : connection_pool .PreferRW ,
462
462
}
463
463
464
464
err = test_helpers .ProcessListenOnInstance (args )
@@ -468,8 +468,8 @@ func TestRoundRobinStrategy_NoReplica(t *testing.T) {
468
468
args = test_helpers.ListenOnInstanceArgs {
469
469
ServersNumber : serversNumber ,
470
470
ExpectedPorts : allPorts ,
471
- ConnPool : connPool ,
472
- Mode : connection_pool .PreferRO ,
471
+ ConnPool : connPool ,
472
+ Mode : connection_pool .PreferRO ,
473
473
}
474
474
475
475
err = test_helpers .ProcessListenOnInstance (args )
@@ -506,8 +506,8 @@ func TestRoundRobinStrategy_NoMaster(t *testing.T) {
506
506
args := test_helpers.ListenOnInstanceArgs {
507
507
ServersNumber : serversNumber ,
508
508
ExpectedPorts : allPorts ,
509
- ConnPool : connPool ,
510
- Mode : connection_pool .ANY ,
509
+ ConnPool : connPool ,
510
+ Mode : connection_pool .ANY ,
511
511
}
512
512
513
513
err = test_helpers .ProcessListenOnInstance (args )
@@ -517,8 +517,8 @@ func TestRoundRobinStrategy_NoMaster(t *testing.T) {
517
517
args = test_helpers.ListenOnInstanceArgs {
518
518
ServersNumber : serversNumber ,
519
519
ExpectedPorts : allPorts ,
520
- ConnPool : connPool ,
521
- Mode : connection_pool .RO ,
520
+ ConnPool : connPool ,
521
+ Mode : connection_pool .RO ,
522
522
}
523
523
524
524
err = test_helpers .ProcessListenOnInstance (args )
@@ -528,8 +528,8 @@ func TestRoundRobinStrategy_NoMaster(t *testing.T) {
528
528
args = test_helpers.ListenOnInstanceArgs {
529
529
ServersNumber : serversNumber ,
530
530
ExpectedPorts : allPorts ,
531
- ConnPool : connPool ,
532
- Mode : connection_pool .PreferRW ,
531
+ ConnPool : connPool ,
532
+ Mode : connection_pool .PreferRW ,
533
533
}
534
534
535
535
err = test_helpers .ProcessListenOnInstance (args )
@@ -539,8 +539,8 @@ func TestRoundRobinStrategy_NoMaster(t *testing.T) {
539
539
args = test_helpers.ListenOnInstanceArgs {
540
540
ServersNumber : serversNumber ,
541
541
ExpectedPorts : allPorts ,
542
- ConnPool : connPool ,
543
- Mode : connection_pool .PreferRO ,
542
+ ConnPool : connPool ,
543
+ Mode : connection_pool .PreferRO ,
544
544
}
545
545
546
546
err = test_helpers .ProcessListenOnInstance (args )
@@ -584,8 +584,8 @@ func TestUpdateInstancesRoles(t *testing.T) {
584
584
args := test_helpers.ListenOnInstanceArgs {
585
585
ServersNumber : serversNumber ,
586
586
ExpectedPorts : allPorts ,
587
- ConnPool : connPool ,
588
- Mode : connection_pool .ANY ,
587
+ ConnPool : connPool ,
588
+ Mode : connection_pool .ANY ,
589
589
}
590
590
591
591
err = test_helpers .ProcessListenOnInstance (args )
@@ -595,8 +595,8 @@ func TestUpdateInstancesRoles(t *testing.T) {
595
595
args = test_helpers.ListenOnInstanceArgs {
596
596
ServersNumber : serversNumber ,
597
597
ExpectedPorts : masterPorts ,
598
- ConnPool : connPool ,
599
- Mode : connection_pool .RW ,
598
+ ConnPool : connPool ,
599
+ Mode : connection_pool .RW ,
600
600
}
601
601
602
602
err = test_helpers .ProcessListenOnInstance (args )
@@ -606,8 +606,8 @@ func TestUpdateInstancesRoles(t *testing.T) {
606
606
args = test_helpers.ListenOnInstanceArgs {
607
607
ServersNumber : serversNumber ,
608
608
ExpectedPorts : replicaPorts ,
609
- ConnPool : connPool ,
610
- Mode : connection_pool .RO ,
609
+ ConnPool : connPool ,
610
+ Mode : connection_pool .RO ,
611
611
}
612
612
613
613
err = test_helpers .ProcessListenOnInstance (args )
@@ -617,8 +617,8 @@ func TestUpdateInstancesRoles(t *testing.T) {
617
617
args = test_helpers.ListenOnInstanceArgs {
618
618
ServersNumber : serversNumber ,
619
619
ExpectedPorts : masterPorts ,
620
- ConnPool : connPool ,
621
- Mode : connection_pool .PreferRW ,
620
+ ConnPool : connPool ,
621
+ Mode : connection_pool .PreferRW ,
622
622
}
623
623
624
624
err = test_helpers .ProcessListenOnInstance (args )
@@ -628,8 +628,8 @@ func TestUpdateInstancesRoles(t *testing.T) {
628
628
args = test_helpers.ListenOnInstanceArgs {
629
629
ServersNumber : serversNumber ,
630
630
ExpectedPorts : replicaPorts ,
631
- ConnPool : connPool ,
632
- Mode : connection_pool .PreferRO ,
631
+ ConnPool : connPool ,
632
+ Mode : connection_pool .PreferRO ,
633
633
}
634
634
635
635
err = test_helpers .ProcessListenOnInstance (args )
@@ -655,8 +655,8 @@ func TestUpdateInstancesRoles(t *testing.T) {
655
655
args = test_helpers.ListenOnInstanceArgs {
656
656
ServersNumber : serversNumber ,
657
657
ExpectedPorts : allPorts ,
658
- ConnPool : connPool ,
659
- Mode : connection_pool .ANY ,
658
+ ConnPool : connPool ,
659
+ Mode : connection_pool .ANY ,
660
660
}
661
661
662
662
err = test_helpers .Retry (test_helpers .ProcessListenOnInstance , args , defaultCountRetry , defaultTimeoutRetry )
@@ -666,8 +666,8 @@ func TestUpdateInstancesRoles(t *testing.T) {
666
666
args = test_helpers.ListenOnInstanceArgs {
667
667
ServersNumber : serversNumber ,
668
668
ExpectedPorts : masterPorts ,
669
- ConnPool : connPool ,
670
- Mode : connection_pool .RW ,
669
+ ConnPool : connPool ,
670
+ Mode : connection_pool .RW ,
671
671
}
672
672
673
673
err = test_helpers .Retry (test_helpers .ProcessListenOnInstance , args , defaultCountRetry , defaultTimeoutRetry )
@@ -677,8 +677,8 @@ func TestUpdateInstancesRoles(t *testing.T) {
677
677
args = test_helpers.ListenOnInstanceArgs {
678
678
ServersNumber : serversNumber ,
679
679
ExpectedPorts : replicaPorts ,
680
- ConnPool : connPool ,
681
- Mode : connection_pool .RO ,
680
+ ConnPool : connPool ,
681
+ Mode : connection_pool .RO ,
682
682
}
683
683
684
684
err = test_helpers .Retry (test_helpers .ProcessListenOnInstance , args , defaultCountRetry , defaultTimeoutRetry )
@@ -688,8 +688,8 @@ func TestUpdateInstancesRoles(t *testing.T) {
688
688
args = test_helpers.ListenOnInstanceArgs {
689
689
ServersNumber : serversNumber ,
690
690
ExpectedPorts : masterPorts ,
691
- ConnPool : connPool ,
692
- Mode : connection_pool .PreferRW ,
691
+ ConnPool : connPool ,
692
+ Mode : connection_pool .PreferRW ,
693
693
}
694
694
695
695
err = test_helpers .Retry (test_helpers .ProcessListenOnInstance , args , defaultCountRetry , defaultTimeoutRetry )
@@ -699,8 +699,8 @@ func TestUpdateInstancesRoles(t *testing.T) {
699
699
args = test_helpers.ListenOnInstanceArgs {
700
700
ServersNumber : serversNumber ,
701
701
ExpectedPorts : replicaPorts ,
702
- ConnPool : connPool ,
703
- Mode : connection_pool .PreferRO ,
702
+ ConnPool : connPool ,
703
+ Mode : connection_pool .PreferRO ,
704
704
}
705
705
706
706
err = test_helpers .Retry (test_helpers .ProcessListenOnInstance , args , defaultCountRetry , defaultTimeoutRetry )
0 commit comments