@@ -701,22 +701,22 @@ func TestFromStringList(t *testing.T) {
701
701
for _ , tc := range []struct {
702
702
name string
703
703
in * pb.Route_StringList
704
- expect types.List
704
+ expect types.Set
705
705
}{
706
706
{
707
707
"null" ,
708
708
nil ,
709
- types .ListNull (types .StringType ),
709
+ types .SetNull (types .StringType ),
710
710
},
711
711
{
712
712
"empty" ,
713
713
& pb.Route_StringList {},
714
- types .ListValueMust (types .StringType , []attr.Value {}),
714
+ types .SetValueMust (types .StringType , []attr.Value {}),
715
715
},
716
716
{
717
717
"entries" ,
718
718
& pb.Route_StringList {Values : []string {"a" , "b" , "c" }},
719
- types .ListValueMust (types .StringType , []attr.Value {
719
+ types .SetValueMust (types .StringType , []attr.Value {
720
720
types .StringValue ("a" ), types .StringValue ("b" ), types .StringValue ("c" ),
721
721
}),
722
722
},
@@ -769,31 +769,31 @@ func TestToRouteStringList(t *testing.T) {
769
769
770
770
for _ , tc := range []struct {
771
771
name string
772
- in types.List
772
+ in types.Set
773
773
expect * pb.Route_StringList
774
774
errorCount int
775
775
}{
776
776
{
777
777
"null" ,
778
- types .ListNull (types .StringType ),
778
+ types .SetNull (types .StringType ),
779
779
nil ,
780
780
0 ,
781
781
},
782
782
{
783
783
"invalid" ,
784
- types .ListValueMust (types .BoolType , []attr.Value {types .BoolValue (true )}),
784
+ types .SetValueMust (types .BoolType , []attr.Value {types .BoolValue (true )}),
785
785
nil ,
786
786
1 ,
787
787
},
788
788
{
789
789
"empty" ,
790
- types .ListValueMust (types .StringType , []attr.Value {}),
790
+ types .SetValueMust (types .StringType , []attr.Value {}),
791
791
& pb.Route_StringList {Values : []string {}},
792
792
0 ,
793
793
},
794
794
{
795
795
"entries" ,
796
- types .ListValueMust (types .StringType , []attr.Value {
796
+ types .SetValueMust (types .StringType , []attr.Value {
797
797
types .StringValue ("a" ), types .StringValue ("b" ), types .StringValue ("c" ),
798
798
}),
799
799
& pb.Route_StringList {Values : []string {
@@ -816,31 +816,31 @@ func TestToSettingsStringList(t *testing.T) {
816
816
817
817
for _ , tc := range []struct {
818
818
name string
819
- in types.List
819
+ in types.Set
820
820
expect * pb.Settings_StringList
821
821
errorCount int
822
822
}{
823
823
{
824
824
"null" ,
825
- types .ListNull (types .StringType ),
825
+ types .SetNull (types .StringType ),
826
826
nil ,
827
827
0 ,
828
828
},
829
829
{
830
830
"invalid" ,
831
- types .ListValueMust (types .BoolType , []attr.Value {types .BoolValue (true )}),
831
+ types .SetValueMust (types .BoolType , []attr.Value {types .BoolValue (true )}),
832
832
nil ,
833
833
1 ,
834
834
},
835
835
{
836
836
"empty" ,
837
- types .ListValueMust (types .StringType , []attr.Value {}),
837
+ types .SetValueMust (types .StringType , []attr.Value {}),
838
838
& pb.Settings_StringList {Values : []string {}},
839
839
0 ,
840
840
},
841
841
{
842
842
"entries" ,
843
- types .ListValueMust (types .StringType , []attr.Value {
843
+ types .SetValueMust (types .StringType , []attr.Value {
844
844
types .StringValue ("a" ), types .StringValue ("b" ), types .StringValue ("c" ),
845
845
}),
846
846
& pb.Settings_StringList {Values : []string {
0 commit comments