mut['platform_name'], mut['serial_port'], mut['mount_point']) # Set up parameters for test specification filter function (we need to set toolchains per target here) use_default_toolchain = 'default' in opts.toolchains_filter.split( ',') if opts.toolchains_filter is not None else True use_supported_toolchains = 'all' in opts.toolchains_filter.split( ',') if opts.toolchains_filter is not None else False toolchain_filter = opts.toolchains_filter platform_name_filter = opts.general_filter_regex.split( ',' ) if opts.general_filter_regex is not None else opts.general_filter_regex # Test specification with information about each target and associated toolchain test_spec = get_autodetected_TEST_SPEC( muts_list, use_default_toolchain=use_default_toolchain, use_supported_toolchains=use_supported_toolchains, toolchain_filter=toolchain_filter, platform_name_filter=platform_name_filter) # MUTs configuration auto-detection MUTs = get_autodetected_MUTS(muts_list) else: # Open file with test specification # test_spec_filename tells script which targets and their toolchain(s) # should be covered by the test scenario test_spec = get_json_data_from_file( opts.test_spec_filename) if opts.test_spec_filename else None if test_spec is None: if not opts.test_spec_filename: parser.print_help() exit(-1)
mbeds = mbed_lstools.create() muts_list = mbeds.list_mbeds_ext() if hasattr(mbeds, 'list_mbeds_ext') else mbeds.list_mbeds() for mut in muts_list: print "MBEDLS: Detected %s, port: %s, mounted: %s"% (mut['platform_name_unique'] if 'platform_name_unique' in mut else mut['platform_name'], mut['serial_port'], mut['mount_point']) # Set up parameters for test specification filter function (we need to set toolchains per target here) use_default_toolchain = 'default' in opts.toolchains_filter.split(',') if opts.toolchains_filter is not None else True use_supported_toolchains = 'all' in opts.toolchains_filter.split(',') if opts.toolchains_filter is not None else False toolchain_filter = opts.toolchains_filter platform_name_filter = opts.general_filter_regex.split(',') if opts.general_filter_regex is not None else opts.general_filter_regex # Test specification with information about each target and associated toolchain test_spec = get_autodetected_TEST_SPEC(muts_list, use_default_toolchain=use_default_toolchain, use_supported_toolchains=use_supported_toolchains, toolchain_filter=toolchain_filter, platform_name_filter=platform_name_filter) # MUTs configuration auto-detection MUTs = get_autodetected_MUTS(muts_list) else: # Open file with test specification # test_spec_filename tells script which targets and their toolchain(s) # should be covered by the test scenario test_spec = get_json_data_from_file(opts.test_spec_filename) if opts.test_spec_filename else None if test_spec is None: if not opts.test_spec_filename: parser.print_help() exit(-1) # Get extra MUTs if applicable