# facter should be able to load facts from multiple external-dir's specified # in the configuration file test_name "C99995: config file supports external-dir for multiple fact directories" do tag 'risk:medium' require 'json' require 'facter/acceptance/user_fact_utils' extend Facter::Acceptance::UserFactUtils agents.each do |agent| step "Agent #{agent}: create external fact directories and a external fact in each and a config file" do external_dir_1 = agent.tmpdir('external_dir_1') external_dir_2 = agent.tmpdir('external_dir_2') ext = get_external_fact_script_extension(agent['platform']) external_fact_1 = File.join(external_dir_1, "external_fact#{ext}") external_fact_2 = File.join(external_dir_2, "external_fact#{ext}") create_remote_file(agent, external_fact_1, external_fact_content(agent['platform'], 'external_fact_1', 'external_value_1')) create_remote_file(agent, external_fact_2, external_fact_content(agent['platform'], 'external_fact_2', 'external_value_2')) on(agent, "chmod +x '#{external_fact_1}' '#{external_fact_2}'") config_dir = agent.tmpdir("config_dir") config_file = File.join(config_dir, "facter.conf") config_content = <