From f089a1a2321e77bfb5f60c2cd79dac14eac9bf63 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Mon, 19 Jun 2017 18:30:13 +0300 Subject: Move project into intermediate sub-directory --- libhello/tests/.gitignore | 1 + libhello/tests/build/.gitignore | 1 + libhello/tests/build/bootstrap.build | 5 +++++ libhello/tests/build/root.build | 14 ++++++++++++++ libhello/tests/buildfile | 1 + libhello/tests/test/buildfile | 4 ++++ libhello/tests/test/driver.cxx | 11 +++++++++++ libhello/tests/test/test.out | 1 + 8 files changed, 38 insertions(+) create mode 100644 libhello/tests/.gitignore create mode 100644 libhello/tests/build/.gitignore create mode 100644 libhello/tests/build/bootstrap.build create mode 100644 libhello/tests/build/root.build create mode 100644 libhello/tests/buildfile create mode 100644 libhello/tests/test/buildfile create mode 100644 libhello/tests/test/driver.cxx create mode 100644 libhello/tests/test/test.out (limited to 'libhello/tests') diff --git a/libhello/tests/.gitignore b/libhello/tests/.gitignore new file mode 100644 index 0000000..e54525b --- /dev/null +++ b/libhello/tests/.gitignore @@ -0,0 +1 @@ +driver diff --git a/libhello/tests/build/.gitignore b/libhello/tests/build/.gitignore new file mode 100644 index 0000000..225c27f --- /dev/null +++ b/libhello/tests/build/.gitignore @@ -0,0 +1 @@ +config.build diff --git a/libhello/tests/build/bootstrap.build b/libhello/tests/build/bootstrap.build new file mode 100644 index 0000000..2c2de24 --- /dev/null +++ b/libhello/tests/build/bootstrap.build @@ -0,0 +1,5 @@ +project = # Unnamed subproject. + +using config +using dist +using test diff --git a/libhello/tests/build/root.build b/libhello/tests/build/root.build new file mode 100644 index 0000000..a2ee38a --- /dev/null +++ b/libhello/tests/build/root.build @@ -0,0 +1,14 @@ +cxx.std = 11 + +using cxx + +hxx{*}: extension = hxx +cxx{*}: extension = cxx + +# Every exe{} in this subproject is by default a test. +# +exe{*}: test = true + +# Specify the test target for cross-testing. +# +test.target = $cxx.target diff --git a/libhello/tests/buildfile b/libhello/tests/buildfile new file mode 100644 index 0000000..1a8bcc9 --- /dev/null +++ b/libhello/tests/buildfile @@ -0,0 +1 @@ +./: test/ diff --git a/libhello/tests/test/buildfile b/libhello/tests/test/buildfile new file mode 100644 index 0000000..a46969d --- /dev/null +++ b/libhello/tests/test/buildfile @@ -0,0 +1,4 @@ +import libs = libhello%lib{hello} + +exe{driver}: cxx{driver} $libs +exe{driver}: test.output = test.out diff --git a/libhello/tests/test/driver.cxx b/libhello/tests/test/driver.cxx new file mode 100644 index 0000000..38937f0 --- /dev/null +++ b/libhello/tests/test/driver.cxx @@ -0,0 +1,11 @@ +// file: tests/test/driver.cxx -*- C++ -*- + +#include + +int +main () +{ + using hello::say; + + say ("World"); +} diff --git a/libhello/tests/test/test.out b/libhello/tests/test/test.out new file mode 100644 index 0000000..8ab686e --- /dev/null +++ b/libhello/tests/test/test.out @@ -0,0 +1 @@ +Hello, World! -- cgit v1.1