File tree 1 file changed +10
-3
lines changed
site/e2e/tests/deployment
1 file changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -26,12 +26,13 @@ const expectConfigOption = async (
26
26
config : API . DeploymentConfig ,
27
27
flag : string ,
28
28
) => {
29
- let value = config . options . find ( ( option ) => option . flag === flag ) ?. value ;
30
- if ( value === undefined ) {
29
+ const opt = config . options . find ( ( option ) => option . flag === flag ) ;
30
+ if ( opt === undefined ) {
31
31
throw new Error ( `Option with env ${ flag } has undefined value.` ) ;
32
32
}
33
33
34
- let type = "" ;
34
+ let type = "" ,
35
+ value = opt . value ;
35
36
if ( typeof value === "boolean" ) {
36
37
type = value ? "option-enabled" : "option-disabled" ;
37
38
value = value ? "Enabled" : "Disabled" ;
@@ -48,6 +49,12 @@ const expectConfigOption = async (
48
49
type = "option-value-json" ;
49
50
}
50
51
52
+ // Special cases
53
+ if ( opt . flag === "strict-transport-security" && opt . value === 0 ) {
54
+ type = "option-value-string" ;
55
+ value = "Disabled" ;
56
+ }
57
+
51
58
const configOption = page . locator (
52
59
`div.options-table .option-${ flag } .${ type } ` ,
53
60
) ;
You can’t perform that action at this time.
0 commit comments