]> git.proxmox.com Git - ceph.git/blame - ceph/src/boost/tools/build/test/wrong_project.py
update ceph source to reef 18.1.2
[ceph.git] / ceph / src / boost / tools / build / test / wrong_project.py
CommitLineData
7c673cae
FG
1#!/usr/bin/python
2
3# Copyright Vladimir Prus 2005.
4# Distributed under the Boost Software License, Version 1.0.
1e59de90
TL
5# (See accompanying file LICENSE.txt or copy at
6# https://www.bfgroup.xyz/b2/LICENSE.txt)
7c673cae
FG
7
8# Regression test. When Jamfile contained "using whatever ; " and the 'whatever'
9# module declared a project, then all targets in Jamfile were considered to be
10# declared in the project associated with 'whatever', not with the Jamfile.
11
12import BoostBuild
13
14t = BoostBuild.Tester(use_test_config=False)
15
16t.write("a.cpp", "int main() {}\n")
17
18t.write("jamroot.jam", """\
19using some_tool ;
20exe a : a.cpp ;
21""")
22
23t.write("some_tool.jam", """\
24import project ;
25project.initialize $(__name__) ;
26rule init ( ) { }
27""")
28
29t.write("some_tool.py", """\
30from b2.manager import get_manager
31get_manager().projects().initialize(__name__)
32def init():
33 pass
34""")
35
36t.run_build_system()
b32b8144 37t.expect_addition("bin/$toolset/debug*/a.exe")
7c673cae
FG
38
39t.cleanup()