Skip to content

Commit cac7bba

Browse files
Copilotjaviercn
andcommitted
Fix test assertions to expect Accept-Encoding instead of Content-Encoding for Vary header
Co-authored-by: javiercn <[email protected]>
1 parent c91869c commit cac7bba

File tree

1 file changed

+20
-20
lines changed

1 file changed

+20
-20
lines changed

test/Microsoft.NET.Sdk.StaticWebAssets.Tests/StaticWebAssets/ApplyCompressionNegotiationTest.cs

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ public void AppliesContentNegotiationRules_ForExistingAssets()
8383
new () { Name = "Content-Encoding", Value = "gzip" },
8484
new () { Name = "Content-Length", Value = "9" },
8585
new () { Name = "Content-Type", Value = "text/javascript" },
86-
new () { Name = "Vary", Value = "Content-Encoding" }
86+
new () { Name = "Vary", Value = "Accept-Encoding" }
8787
],
8888
EndpointProperties = [],
8989
Selectors = [ new () { Name = "Content-Encoding", Value = "gzip", Quality = "0.100000000000" } ],
@@ -109,7 +109,7 @@ public void AppliesContentNegotiationRules_ForExistingAssets()
109109
new () { Name = "Content-Encoding", Value = "gzip" },
110110
new () { Name = "Content-Length", Value = "9" },
111111
new () { Name = "Content-Type", Value = "text/javascript" },
112-
new () { Name = "Vary", Value = "Content-Encoding" }
112+
new () { Name = "Vary", Value = "Accept-Encoding" }
113113
],
114114
EndpointProperties = [],
115115
Selectors = []
@@ -874,7 +874,7 @@ public void AppliesContentNegotiationRules_ToAllRelatedAssetEndpoints()
874874
[
875875
new () { Name = "Content-Encoding", Value = "gzip" },
876876
new () { Name = "Content-Type", Value = "text/javascript" },
877-
new () { Name = "Vary", Value = "Content-Encoding" }
877+
new () { Name = "Vary", Value = "Accept-Encoding" }
878878
],
879879
EndpointProperties = [],
880880
Selectors = [ new () { Name = "Content-Encoding", Value = "gzip", Quality = "0.100000000000" } ],
@@ -898,7 +898,7 @@ public void AppliesContentNegotiationRules_ToAllRelatedAssetEndpoints()
898898
[
899899
new () { Name = "Content-Encoding", Value = "gzip" },
900900
new () { Name = "Content-Type", Value = "text/javascript" },
901-
new () { Name = "Vary", Value = "Content-Encoding" }
901+
new () { Name = "Vary", Value = "Accept-Encoding" }
902902
],
903903
EndpointProperties = [],
904904
Selectors = [ new () { Name = "Content-Encoding", Value = "gzip", Quality = "0.100000000000" } ],
@@ -922,7 +922,7 @@ public void AppliesContentNegotiationRules_ToAllRelatedAssetEndpoints()
922922
[
923923
new () { Name = "Content-Encoding", Value = "gzip" },
924924
new () { Name = "Content-Type", Value = "text/javascript" },
925-
new () { Name = "Vary", Value = "Content-Encoding" }
925+
new () { Name = "Vary", Value = "Accept-Encoding" }
926926
],
927927
EndpointProperties = [],
928928
Selectors = []
@@ -977,7 +977,7 @@ public void AppliesContentNegotiationRules_IgnoresAlreadyProcessedEndpoints()
977977
[
978978
new () { Name = "Content-Encoding", Value = "gzip" },
979979
new (){ Name = "Content-Type", Value = "text/javascript" },
980-
new (){ Name = "Vary", Value = "Content-Encoding" }
980+
new (){ Name = "Vary", Value = "Accept-Encoding" }
981981
],
982982
EndpointProperties = [],
983983
Selectors = [ new StaticWebAssetEndpointSelector { Name = "Content-Encoding", Value = "gzip", Quality = "0.100000000000" } ],
@@ -1001,7 +1001,7 @@ public void AppliesContentNegotiationRules_IgnoresAlreadyProcessedEndpoints()
10011001
[
10021002
new (){ Name = "Content-Encoding", Value = "gzip" },
10031003
new (){ Name = "Content-Type", Value = "text/javascript" },
1004-
new (){ Name = "Vary", Value = "Content-Encoding" }
1004+
new (){ Name = "Vary", Value = "Accept-Encoding" }
10051005
],
10061006
EndpointProperties = [],
10071007
Selectors = [ new () { Name = "Content-Encoding", Value = "gzip", Quality = "0.100000000000" } ],
@@ -1025,7 +1025,7 @@ public void AppliesContentNegotiationRules_IgnoresAlreadyProcessedEndpoints()
10251025
[
10261026
new () { Name = "Content-Encoding", Value = "gzip" },
10271027
new () { Name = "Content-Type", Value = "text/javascript" },
1028-
new () { Name = "Vary", Value = "Content-Encoding" }
1028+
new () { Name = "Vary", Value = "Accept-Encoding" }
10291029
],
10301030
EndpointProperties = [],
10311031
Selectors = []
@@ -1048,7 +1048,7 @@ public void AppliesContentNegotiationRules_IgnoresAlreadyProcessedEndpoints()
10481048
[
10491049
new () { Name = "Content-Encoding", Value = "gzip" },
10501050
new () { Name = "Content-Type", Value = "text/javascript" },
1051-
new () { Name = "Vary", Value = "Content-Encoding" }
1051+
new () { Name = "Vary", Value = "Accept-Encoding" }
10521052
],
10531053
EndpointProperties = [],
10541054
Selectors = [ new StaticWebAssetEndpointSelector { Name = "Content-Encoding", Value = "gzip", Quality = "0.100000000000" } ],
@@ -1072,7 +1072,7 @@ public void AppliesContentNegotiationRules_IgnoresAlreadyProcessedEndpoints()
10721072
[
10731073
new () { Name = "Content-Encoding", Value = "gzip" },
10741074
new () { Name = "Content-Type", Value = "text/javascript" },
1075-
new () { Name = "Vary", Value = "Content-Encoding" }
1075+
new () { Name = "Vary", Value = "Accept-Encoding" }
10761076
],
10771077
EndpointProperties = [],
10781078
Selectors = [ new StaticWebAssetEndpointSelector { Name = "Content-Encoding", Value = "gzip", Quality = "0.100000000000" } ],
@@ -1096,7 +1096,7 @@ public void AppliesContentNegotiationRules_IgnoresAlreadyProcessedEndpoints()
10961096
[
10971097
new () { Name = "Content-Encoding", Value = "gzip" },
10981098
new () { Name = "Content-Type", Value = "text/javascript" },
1099-
new () { Name = "Vary", Value = "Content-Encoding" }
1099+
new () { Name = "Vary", Value = "Accept-Encoding" }
11001100
],
11011101
EndpointProperties = [],
11021102
Selectors = []
@@ -1167,7 +1167,7 @@ public void AppliesContentNegotiationRules_ProcessesNewCompressedFormatsWhenAvai
11671167
[
11681168
new () { Name = "Content-Encoding", Value = "gzip" },
11691169
new (){ Name = "Content-Type", Value = "text/javascript" },
1170-
new (){ Name = "Vary", Value = "Content-Encoding" }
1170+
new (){ Name = "Vary", Value = "Accept-Encoding" }
11711171
],
11721172
EndpointProperties = [],
11731173
Selectors = [ new StaticWebAssetEndpointSelector { Name = "Content-Encoding", Value = "gzip", Quality = "0.100000000000" } ],
@@ -1191,7 +1191,7 @@ public void AppliesContentNegotiationRules_ProcessesNewCompressedFormatsWhenAvai
11911191
[
11921192
new (){ Name = "Content-Encoding", Value = "gzip" },
11931193
new (){ Name = "Content-Type", Value = "text/javascript" },
1194-
new (){ Name = "Vary", Value = "Content-Encoding" }
1194+
new (){ Name = "Vary", Value = "Accept-Encoding" }
11951195
],
11961196
EndpointProperties = [],
11971197
Selectors = [ new () { Name = "Content-Encoding", Value = "gzip", Quality = "0.100000000000" } ],
@@ -1215,7 +1215,7 @@ public void AppliesContentNegotiationRules_ProcessesNewCompressedFormatsWhenAvai
12151215
[
12161216
new () { Name = "Content-Encoding", Value = "gzip" },
12171217
new () { Name = "Content-Type", Value = "text/javascript" },
1218-
new () { Name = "Vary", Value = "Content-Encoding" }
1218+
new () { Name = "Vary", Value = "Accept-Encoding" }
12191219
],
12201220
EndpointProperties = [],
12211221
Selectors = []
@@ -1249,7 +1249,7 @@ public void AppliesContentNegotiationRules_ProcessesNewCompressedFormatsWhenAvai
12491249
[
12501250
new () { Name = "Content-Encoding", Value = "gzip" },
12511251
new () { Name = "Content-Type", Value = "text/javascript" },
1252-
new () { Name = "Vary", Value = "Content-Encoding" }
1252+
new () { Name = "Vary", Value = "Accept-Encoding" }
12531253
],
12541254
EndpointProperties = [],
12551255
Selectors = [ new StaticWebAssetEndpointSelector { Name = "Content-Encoding", Value = "gzip", Quality = "0.100000000000" } ],
@@ -1262,7 +1262,7 @@ public void AppliesContentNegotiationRules_ProcessesNewCompressedFormatsWhenAvai
12621262
[
12631263
new () { Name = "Content-Encoding", Value = "br" },
12641264
new () { Name = "Content-Type", Value = "text/javascript" },
1265-
new () { Name = "Vary", Value = "Content-Encoding" }
1265+
new () { Name = "Vary", Value = "Accept-Encoding" }
12661266
],
12671267
EndpointProperties = [],
12681268
Selectors = [ new StaticWebAssetEndpointSelector { Name = "Content-Encoding", Value = "br", Quality = "0.100000000000" } ],
@@ -1286,7 +1286,7 @@ public void AppliesContentNegotiationRules_ProcessesNewCompressedFormatsWhenAvai
12861286
[
12871287
new () { Name = "Content-Encoding", Value = "gzip" },
12881288
new () { Name = "Content-Type", Value = "text/javascript" },
1289-
new () { Name = "Vary", Value = "Content-Encoding" }
1289+
new () { Name = "Vary", Value = "Accept-Encoding" }
12901290
],
12911291
EndpointProperties = [],
12921292
Selectors = [ new StaticWebAssetEndpointSelector { Name = "Content-Encoding", Value = "gzip", Quality = "0.100000000000" } ],
@@ -1299,7 +1299,7 @@ public void AppliesContentNegotiationRules_ProcessesNewCompressedFormatsWhenAvai
12991299
[
13001300
new () { Name = "Content-Encoding", Value = "br" },
13011301
new () { Name = "Content-Type", Value = "text/javascript" },
1302-
new () { Name = "Vary", Value = "Content-Encoding" }
1302+
new () { Name = "Vary", Value = "Accept-Encoding" }
13031303
],
13041304
EndpointProperties = [],
13051305
Selectors = [ new StaticWebAssetEndpointSelector { Name = "Content-Encoding", Value = "br", Quality = "0.100000000000" } ],
@@ -1323,7 +1323,7 @@ public void AppliesContentNegotiationRules_ProcessesNewCompressedFormatsWhenAvai
13231323
[
13241324
new () { Name = "Content-Encoding", Value = "gzip" },
13251325
new () { Name = "Content-Type", Value = "text/javascript" },
1326-
new () { Name = "Vary", Value = "Content-Encoding" }
1326+
new () { Name = "Vary", Value = "Accept-Encoding" }
13271327
],
13281328
EndpointProperties = [],
13291329
Selectors = []
@@ -1336,7 +1336,7 @@ public void AppliesContentNegotiationRules_ProcessesNewCompressedFormatsWhenAvai
13361336
[
13371337
new () { Name = "Content-Encoding", Value = "br" },
13381338
new () { Name = "Content-Type", Value = "text/javascript" },
1339-
new () { Name = "Vary", Value = "Content-Encoding" }
1339+
new () { Name = "Vary", Value = "Accept-Encoding" }
13401340
],
13411341
EndpointProperties = [],
13421342
Selectors = []

0 commit comments

Comments
 (0)