@@ -836,6 +836,7 @@ func TestGetClusterSharding(t *testing.T) {
836
836
{
837
837
name : "Default sharding with statefulset" ,
838
838
envsSetter : func (t * testing.T ) {
839
+ t .Helper ()
839
840
t .Setenv (common .EnvControllerReplicas , "1" )
840
841
},
841
842
cleanup : func () {},
@@ -847,6 +848,7 @@ func TestGetClusterSharding(t *testing.T) {
847
848
{
848
849
name : "Default sharding with deployment" ,
849
850
envsSetter : func (t * testing.T ) {
851
+ t .Helper ()
850
852
t .Setenv (common .EnvAppControllerName , common .DefaultApplicationControllerName )
851
853
},
852
854
cleanup : func () {},
@@ -858,6 +860,7 @@ func TestGetClusterSharding(t *testing.T) {
858
860
{
859
861
name : "Default sharding with deployment and multiple replicas" ,
860
862
envsSetter : func (t * testing.T ) {
863
+ t .Helper ()
861
864
t .Setenv (common .EnvAppControllerName , "argocd-application-controller-multi-replicas" )
862
865
},
863
866
cleanup : func () {},
@@ -869,6 +872,7 @@ func TestGetClusterSharding(t *testing.T) {
869
872
{
870
873
name : "Statefulset multiple replicas" ,
871
874
envsSetter : func (t * testing.T ) {
875
+ t .Helper ()
872
876
t .Setenv (common .EnvControllerReplicas , "3" )
873
877
osHostnameFunction = func () (string , error ) { return "example-shard-3" , nil }
874
878
},
@@ -883,6 +887,7 @@ func TestGetClusterSharding(t *testing.T) {
883
887
{
884
888
name : "Explicit shard with statefulset and 1 replica" ,
885
889
envsSetter : func (t * testing.T ) {
890
+ t .Helper ()
886
891
t .Setenv (common .EnvControllerReplicas , "1" )
887
892
t .Setenv (common .EnvControllerShard , "3" )
888
893
},
@@ -895,6 +900,7 @@ func TestGetClusterSharding(t *testing.T) {
895
900
{
896
901
name : "Explicit shard with statefulset and 2 replica - and to high shard" ,
897
902
envsSetter : func (t * testing.T ) {
903
+ t .Helper ()
898
904
t .Setenv (common .EnvControllerReplicas , "2" )
899
905
t .Setenv (common .EnvControllerShard , "3" )
900
906
},
@@ -907,6 +913,7 @@ func TestGetClusterSharding(t *testing.T) {
907
913
{
908
914
name : "Explicit shard with statefulset and 2 replica" ,
909
915
envsSetter : func (t * testing.T ) {
916
+ t .Helper ()
910
917
t .Setenv (common .EnvControllerReplicas , "2" )
911
918
t .Setenv (common .EnvControllerShard , "1" )
912
919
},
@@ -919,6 +926,7 @@ func TestGetClusterSharding(t *testing.T) {
919
926
{
920
927
name : "Explicit shard with deployment" ,
921
928
envsSetter : func (t * testing.T ) {
929
+ t .Helper ()
922
930
t .Setenv (common .EnvControllerShard , "3" )
923
931
},
924
932
cleanup : func () {},
@@ -930,6 +938,7 @@ func TestGetClusterSharding(t *testing.T) {
930
938
{
931
939
name : "Explicit shard with deployment and multiple replicas will read from configmap" ,
932
940
envsSetter : func (t * testing.T ) {
941
+ t .Helper ()
933
942
t .Setenv (common .EnvAppControllerName , "argocd-application-controller-multi-replicas" )
934
943
t .Setenv (common .EnvControllerShard , "3" )
935
944
},
@@ -942,6 +951,7 @@ func TestGetClusterSharding(t *testing.T) {
942
951
{
943
952
name : "Dynamic sharding but missing deployment" ,
944
953
envsSetter : func (t * testing.T ) {
954
+ t .Helper ()
945
955
t .Setenv (common .EnvAppControllerName , "missing-deployment" )
946
956
},
947
957
cleanup : func () {},
0 commit comments