@@ -733,7 +733,7 @@ def apply_filters(self, **kwargs):
733
733
logger .info ("Selecting default platforms per testsuite scenario" )
734
734
default_platforms = True
735
735
elif emu_filter :
736
- logger .info ("Selecting emulation platforms per testsuite scenraio " )
736
+ logger .info ("Selecting emulation platforms per testsuite scenario " )
737
737
emulation_platforms = True
738
738
elif vendor_filter :
739
739
vendor_platforms = True
@@ -767,32 +767,35 @@ def apply_filters(self, **kwargs):
767
767
platforms = self .platforms
768
768
769
769
platform_config = self .test_config .get ('platforms' , {})
770
+ # test configuration options
771
+ test_config_options = self .test_config .get ('options' , {})
772
+ integration_mode_list = test_config_options .get ('integration_mode' , [])
773
+
770
774
logger .info ("Building initial testsuite list..." )
771
775
772
776
keyed_tests = {}
773
-
774
777
for _ , ts in self .testsuites .items ():
775
- if (
776
- ts .build_on_all
777
- and not platform_filter
778
- and platform_config .get ('increased_platform_scope' , True )
779
- ):
780
- platform_scope = self .platforms
781
- elif ts .integration_platforms :
782
- integration_platforms = list (
778
+ if ts .integration_platforms :
779
+ _integration_platforms = list (
783
780
filter (lambda item : item .name in ts .integration_platforms , self .platforms )
784
781
)
785
- if self .options .integration :
786
- platform_scope = integration_platforms
782
+ else :
783
+ _integration_platforms = []
784
+
785
+ if (ts .build_on_all and not platform_filter and
786
+ platform_config .get ('increased_platform_scope' , True )):
787
+ # if build_on_all is set, we build on all platforms
788
+ platform_scope = self .platforms
789
+ elif ts .integration_platforms and self .options .integration :
790
+ # if integration is set, we build on integration platforms
791
+ platform_scope = _integration_platforms
792
+ elif ts .integration_platforms and not platform_filter :
793
+ # if integration platforms are set, we build on those and integration mode is set
794
+ # for this test suite, we build on integration platforms
795
+ if any (ts .id .startswith (i ) for i in integration_mode_list ):
796
+ platform_scope = _integration_platforms
787
797
else :
788
- platform_scope = platforms
789
- if not platform_filter :
790
- tco = self .test_config .get ('options' , {})
791
- im = tco .get ('integration_mode' , [])
792
- if any (ts .id .startswith (i ) for i in im ):
793
- platform_scope = integration_platforms
794
- else :
795
- platform_scope += integration_platforms
798
+ platform_scope = platforms + _integration_platforms
796
799
else :
797
800
platform_scope = platforms
798
801
0 commit comments