3 # Copyright 2003, 2004, 2005 Vladimir Prus
4 # Distributed under the Boost Software License, Version 1.0.
5 # (See accompanying file LICENSE_1_0.txt or copy at
6 # http://www.boost.org/LICENSE_1_0.txt)
10 # Create a temporary working directory.
11 t = BoostBuild.Tester()
13 # Create the needed files.
14 t.write("jamroot.jam", """\
15 constant FOO : foobar gee ;
20 t.expect_output_lines("foobar gee")
22 # Regression test: when absolute paths were passed to path-constant rule,
23 # Boost.Build failed to recognize path as absolute and prepended the current
25 t.write("jamroot.jam", """\
27 local here = [ path.native [ path.pwd ] ] ;
28 path-constant HERE : $(here) ;
31 ECHO "PWD =" $(here) ;
32 ECHO "path constant =" $(HERE) ;
36 t.write("jamfile.jam", "")
40 t.write("jamfile.jam", """\
41 # This tests that rule 'hello' will be imported to children unlocalized, and
42 # will still access variables in this Jamfile.
45 rule hello ( ) { ECHO "Hello $(x)" ; }
48 t.write("d/jamfile.jam", """\
53 t.write("d/d2/jamfile.jam", """\
59 t.run_build_system(subdir="d/d2")
60 t.expect_output_lines("d: foo\nd2: foo\nd2: bar\nHello 10")