code: def test_default_toolset_on_os(os, expected_toolset):
      """Test that the given toolset is used as the default toolset on the given
      os. Uses hardcoded knowledge of how Boost Build decides on which host OS it
      is currently running. Note that we must not do much after tricking Boost
      Build into believing it has a specific host OS as this might mess up other
      important internal Boost Build state.
      """
  
      t = BoostBuild.Tester(
          "--user-config= --ignore-site-config",
          pass_toolset=False,
          use_test_config=False,
      )
  
      t.write("jamroot.jam", "modules.poke os : .name : %s ;" % os)
  
      # We need to tell the test system to ignore stderr output as attempting to
      # load missing toolsets might cause random failures with which we are not
      # concerned in this test.
      t.run_build_system(stderr=None)
      t.expect_output_lines(
          configuring_default_toolset_message % expected_toolset
      )
  
      t.cleanup()
  
imports: import BoostBuild
label_desc: Use image node_id 2 for calling a global function with example usage: test_default_toolset_on_os(os, expected_toolset) without return types