File tree Expand file tree Collapse file tree 3 files changed +15
-5
lines changed Expand file tree Collapse file tree 3 files changed +15
-5
lines changed Original file line number Diff line number Diff line change @@ -11,16 +11,12 @@ func filterOutDisabledSpecs(specs et.ExtensionTestSpecs) et.ExtensionTestSpecs {
1111		"Alpha" : { // alpha features that are not gated 
1212			"[Feature:StorageVersionAPI]" ,
1313			"[Feature:ClusterTrustBundle]" ,
14- 			"[Feature:SELinuxMount]" ,
15- 			"[FeatureGate:SELinuxMount]" ,
1614			"[Feature:DynamicResourceAllocation]" ,
17- 			"[Feature:VolumeAttributesClass]" , // disabled Beta 
1815			"[sig-cli] Kubectl client Kubectl prune with applyset should apply and prune objects" , // Alpha feature since k8s 1.27 
1916			// 4.19 
2017			"[Feature:PodLevelResources]" ,
2118			"[Feature:PodLogsQuerySplitStreams]" ,
2219			// 4.20 
23- 			"[Feature:OffByDefault]" ,
2420			"[Feature:CBOR]" ,
2521		},
2622		// tests for features that are not implemented in openshift 
Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ package main
22
33import  (
44	"fmt" 
5+ 	"strings" 
56
67	et "github.com/openshift-eng/openshift-tests-extension/pkg/extension/extensiontests" 
78	"k8s.io/kubernetes/pkg/features" 
@@ -15,6 +16,7 @@ func addEnvironmentSelectors(specs et.ExtensionTestSpecs) {
1516	filterByTopology (specs )
1617	filterByNoOptionalCapabilities (specs )
1718	filterByNetwork (specs )
19+ 	filterByFeatureGates (specs )
1820
1921	// LoadBalancer tests in 1.31 require explicit platform-specific skips 
2022	// https://issues.redhat.com/browse/OCPBUGS-38840 
@@ -273,3 +275,15 @@ func filterByNetwork(specs et.ExtensionTestSpecs) {
273275			AddLabel (fmt .Sprintf ("[Skipped:%s]" , network ))
274276	}
275277}
278+ 
279+ // filter all tests from feature gates that are not explicitly enabled 
280+ func  filterByFeatureGates (specs  et.ExtensionTestSpecs ) {
281+ 	for  _ , spec  :=  range  specs  {
282+ 		for  label  :=  range  spec .Labels  {
283+ 			if  strings .Contains (label , "FeatureGate:" ) {
284+ 				featureGate  :=  strings .TrimPrefix (label , "FeatureGate:" )
285+ 				spec .Exclude (et .FeatureGateDisabled (featureGate ))
286+ 			}
287+ 		}
288+ 	}
289+ }
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ NETWORK_SKIPS="\[Skipped:Network/OVNKubernetes\]|\[Feature:Networking-IPv6\]|\[F
3131TEST_SUITE=" ${TEST_SUITE:- parallel} " 
3232COMMON_SKIPS=" \[Slow\]|\[Disruptive\]|\[Flaky\]|\[Disabled:.+\]|\[Skipped:${PLATFORM} \]|${NETWORK_SKIPS} " 
3333#  Skip tests for features that require a TechPreview cluster. TODO: Remove when the feature is enabled by default.
34- COMMON_SKIPS=" \[OCPFeatureGate:VolumeGroupSnapshot\]|${COMMON_SKIPS} " 
34+ COMMON_SKIPS=" \[OCPFeatureGate:VolumeGroupSnapshot\]|\[Feature:OffByDefault\]| ${COMMON_SKIPS} " 
3535
3636case  " ${TEST_SUITE} "   in 
3737serial)
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments