Last change
on this file since 12 was
12,
checked in by landauf, 17 years ago
|
added boost
|
-
Property svn:executable set to
*
|
File size:
1.1 KB
|
Line | |
---|
1 | #!/usr/bin/python |
---|
2 | |
---|
3 | # Copyright (C) FILL SOMETHING HERE 2005. |
---|
4 | # Distributed under the Boost Software License, Version 1.0. (See |
---|
5 | # accompanying file LICENSE_1_0.txt or copy at |
---|
6 | # http://www.boost.org/LICENSE_1_0.txt) |
---|
7 | |
---|
8 | # This file is template for Boost.Build tests. It creates a simple |
---|
9 | # project that builds one exe from one source, and checks that the exe |
---|
10 | # is really created. |
---|
11 | from BoostBuild import Tester, List |
---|
12 | |
---|
13 | # Create a temporary working directory |
---|
14 | t = Tester() |
---|
15 | |
---|
16 | # Create the needed files |
---|
17 | t.write("project-root.jam", "") |
---|
18 | t.write("Jamfile", """ |
---|
19 | exe hello : hello.cpp ; |
---|
20 | """) |
---|
21 | t.write("hello.cpp", """ |
---|
22 | int main() |
---|
23 | { |
---|
24 | return 0; |
---|
25 | } |
---|
26 | |
---|
27 | """) |
---|
28 | |
---|
29 | t.run_build_system() |
---|
30 | |
---|
31 | # First, create a list of three pathnames |
---|
32 | file_list = List("bin/$toolset/debug/") * List("hello.exe hello.obj") |
---|
33 | # Second, assert that those files were added as result of the last build system invocation. |
---|
34 | t.expect_addition(file_list) |
---|
35 | |
---|
36 | # Invoke the build system once again |
---|
37 | t.run_build_system("clean") |
---|
38 | # Check if the files added previously were removed. |
---|
39 | t.expect_removal(file_list) |
---|
40 | |
---|
41 | # Remove temporary directories |
---|
42 | t.cleanup() |
---|
Note: See
TracBrowser
for help on using the repository browser.