code: def test_unresolved_project_references():
      t = BoostBuild.Tester()
  
      __write_appender(t, "appender.jam")
      t.write("a/source._a", "")
      t.write(
          "a/jamfile.jam", "import alias ; alias target : source._a ;"
      )
      t.write(
          "jamroot.jam",
          """\
  import type ;
  type.register AAA : _a ;
  type.register BBB : _b ;
  
  import appender ;
  appender.register aaa-to-bbb : AAA : BBB ;
  
  use-project foo : a ;
  
  bbb b1 : a//target ;
  bbb b2 : /foo//target ;
  bbb b-invalid : invalid//target ;
  bbb b-root-invalid : /invalid//target ;
  bbb b-missing-root : foo//target ;
  bbb b-invalid-target : /foo//invalid ;
  """,
      )
  
      t.run_build_system(["b1", "b2"])
      t.expect_addition("bin/b%d._b" % x for x in range(1, 3))
      t.expect_nothing_more()
  
      t.run_build_system(["b-invalid"], status=1)
      t.expect_output_lines(
          """\
  error: Unable to find file or target named
  error:     'invalid//target'
  error: referred to from project at
  error:     '.'
  error: could not resolve project reference 'invalid'"""
      )
  
      t.run_build_system(["b-root-invalid"], status=1)
      t.expect_output_lines(
          """\
  error: Unable to find file or target named
  error:     '/invalid//target'
  error: referred to from project at
  error:     '.'
  error: could not resolve project reference '/invalid'"""
      )
  
      t.run_build_system(["b-missing-root"], status=1)
      t.expect_output_lines(
          """\
  error: Unable to find file or target named
  error:     'foo//target'
  error: referred to from project at
  error:     '.'
  error: could not resolve project reference 'foo' - possibly missing a """
          "leading slash ('/') character."
      )
  
      t.run_build_system(["b-invalid-target"], status=1)
      t.expect_output_lines(
          """\
  error: Unable to find file or target named
  error:     '/foo//invalid'
  error: referred to from project at
  error:     '.'"""
      )
      t.expect_output_lines(
          "*could not resolve project reference*", False
      )
  
      t.cleanup()
  
imports: import BoostBuild
  import sys
label_desc: Use image node_id 5 for calling a global function with example usage: test_unresolved_project_references() without return types