aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2019-10-19 15:16:40 (GMT)
committerKaren Arutyunov <karen@codesynthesis.com>2019-10-19 15:16:40 (GMT)
commit6bbf6390d95941cd5ead6eba649edc2a7fec9d21 (patch)
treee53fc013def290d6b1e130c1549c56d04346b316
parent23dfd50930bfe3d7135a567e7c67eea21aeece98 (diff)
Fix some testscripts properly setting config.cxx variable
-rw-r--r--tests/pkg-build.testscript19
-rw-r--r--tests/pkg-update.testscript6
2 files changed, 18 insertions, 7 deletions
diff --git a/tests/pkg-build.testscript b/tests/pkg-build.testscript
index cf9c82c..48fe5a9 100644
--- a/tests/pkg-build.testscript
+++ b/tests/pkg-build.testscript
@@ -2709,10 +2709,12 @@ test.options += --no-progress
{
test.arguments += --yes
+ +$cfg_create cxx $config_cxx -d cfg 2>- &cfg/***
+
: direct
:
{
- $clone_root_cfg;
+ $clone_cfg;
cp -r $src/libfoo-1.1.0/ libfoo;
echo "depends: libfoo" >+ libfoo/manifest;
@@ -2729,10 +2731,12 @@ test.options += --no-progress
: indirect
:
{
+ +$clone_cfg
+
: new
:
{
- $clone_root_cfg;
+ $clone_cfg;
cp -r $src/libfoo-1.1.0/ libfoo;
echo "depends: libbar" >+ libfoo/manifest;
@@ -2761,7 +2765,7 @@ test.options += --no-progress
: upgrade
:
{
- $clone_root_cfg;
+ $clone_cfg;
cp -r $src/libfoo-1.1.0/ libfoo;
$rep_add libfoo --type dir;
@@ -3485,8 +3489,13 @@ test.options += --no-progress
{
clone_cfg = cp -pr --no-cleanup ../../cfg ./
- +$build 'dist(../../libhello/@./out/)' \
- $config_cxx config.dist.root=./ \
+ # Distribute using the dedicated configuration to avoid the 'c and cxx
+ # module toolchain pattern mismatch' warning.
+ #
+ +$cfg_create cxx $config_cxx -d cfg 2>- &cfg/***
+
+ +$build 'dist(../../libhello/@./cfg/libhello/)' \
+ config.dist.root=./ \
config.dist.archives=tar.gz 2>! \
&libhello-1.0.1/*** &libhello-1.0.1.tar.gz
diff --git a/tests/pkg-update.testscript b/tests/pkg-update.testscript
index 9a1cf7d..c50b026 100644
--- a/tests/pkg-update.testscript
+++ b/tests/pkg-update.testscript
@@ -48,7 +48,9 @@
&$out/hello/signature.manifest
end
-pkg_configure += -d cfg config.cxx=$quote($recall($cxx.path) $cxx.mode, true) 2>!
+config_cxx = config.cxx=$quote($recall($cxx.path) $cxx.mode, true)
+
+pkg_configure += -d cfg $config_cxx 2>!
pkg_disfigure += -d cfg
pkg_fetch += -d cfg 2>!
pkg_purge += -d cfg
@@ -137,7 +139,7 @@ $* 2>>EOE != 0
: vars
:
{
- +$clone_cfg
+ +$cfg_create cxx $config_cxx -d cfg 2>- &cfg/***
+$rep_fetch $rep/hello --trust $cert_fp &cfg/.bpkg/certs/**
: global-and-local