aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2023-04-13 22:37:06 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2023-04-14 00:42:37 +0300
commitb038abca63e64d73e64fee2c65fcc3f1743c2c4a (patch)
tree5d5ba4d9fa2aa6ff2e7c6e3451c95bd169e9db1c
parente106df8f3a367e2c32548abccb5606a9fc441eae (diff)
Fix 'dropping no longer used variable' warning in testscripts
-rw-r--r--tests/common/dependency-alternatives/t8a/box-1.0.0.tar.gzbin460 -> 479 bytes
-rw-r--r--tests/common/satisfy/libbar-1.2.0.tar.gzbin348 -> 432 bytes
-rw-r--r--tests/common/satisfy/libbox-1.2.0.tar.gzbin0 -> 421 bytes
l---------tests/common/satisfy/t5/libbox-1.2.0.tar.gz1
-rw-r--r--tests/pkg-build.testscript47
-rw-r--r--tests/pkg-configure.testscript10
6 files changed, 56 insertions, 2 deletions
diff --git a/tests/common/dependency-alternatives/t8a/box-1.0.0.tar.gz b/tests/common/dependency-alternatives/t8a/box-1.0.0.tar.gz
index babc96c..f266c46 100644
--- a/tests/common/dependency-alternatives/t8a/box-1.0.0.tar.gz
+++ b/tests/common/dependency-alternatives/t8a/box-1.0.0.tar.gz
Binary files differ
diff --git a/tests/common/satisfy/libbar-1.2.0.tar.gz b/tests/common/satisfy/libbar-1.2.0.tar.gz
index 4572395..f8fb1ec 100644
--- a/tests/common/satisfy/libbar-1.2.0.tar.gz
+++ b/tests/common/satisfy/libbar-1.2.0.tar.gz
Binary files differ
diff --git a/tests/common/satisfy/libbox-1.2.0.tar.gz b/tests/common/satisfy/libbox-1.2.0.tar.gz
new file mode 100644
index 0000000..1f8675a
--- /dev/null
+++ b/tests/common/satisfy/libbox-1.2.0.tar.gz
Binary files differ
diff --git a/tests/common/satisfy/t5/libbox-1.2.0.tar.gz b/tests/common/satisfy/t5/libbox-1.2.0.tar.gz
new file mode 120000
index 0000000..3d49749
--- /dev/null
+++ b/tests/common/satisfy/t5/libbox-1.2.0.tar.gz
@@ -0,0 +1 @@
+../libbox-1.2.0.tar.gz \ No newline at end of file
diff --git a/tests/pkg-build.testscript b/tests/pkg-build.testscript
index aaa7bc4..157a3ef 100644
--- a/tests/pkg-build.testscript
+++ b/tests/pkg-build.testscript
@@ -107,6 +107,7 @@
# |
# |-- t5
# | |-- libbar-1.2.0.tar.gz
+# | |-- libbox-1.2.0.tar.gz
# | `-- repositories.manifest
# |
# |-- t6
@@ -2079,6 +2080,41 @@ test.arguments += --sys-no-query
}
}
}
+
+ : config-vars
+ :
+ {
+ $cfg_create -d cfg cc config.cc.coptions=-Wall 2>- &cfg/***;
+ $rep_add $rep/t5 && $rep_fetch;
+
+ $* --configure-only { config.cc.coptions+=-g }+ libbar \
+ { config.cc.coptions+=-O }+ libbox 2>>EOE;
+ fetched libbar/1.2.0
+ unpacked libbar/1.2.0
+ fetched libbox/1.2.0
+ unpacked libbox/1.2.0
+ configured libbar/1.2.0
+ configured libbox/1.2.0
+ EOE
+
+ cat cfg/build/config.build >>~%EOO%;
+ %.*
+ config.cc.coptions = -Wall
+ %.*
+ EOO
+
+ cat cfg/libbar-1.2.0/build/config.build >>~%EOO%;
+ %.*
+ config.cc.coptions = -Wall -g
+ %.*
+ EOO
+
+ cat cfg/libbox-1.2.0/build/config.build >>~%EOO%
+ %.*
+ config.cc.coptions = -Wall -O
+ %.*
+ EOO
+ }
}
: dependency
@@ -3949,6 +3985,7 @@ test.arguments += --sys-no-query
cat cfg/box-1.0.0/build/config.build >>~%EOO%;
%.*
config.box.backend = libbox
+ %.*
EOO
$pkg_drop box;
@@ -3994,6 +4031,7 @@ test.arguments += --sys-no-query
cat cfg/box-1.0.0/build/config.build >>~%EOO%;
%.*
config.box.backend = libbiz
+ %.*
EOO
$pkg_drop box
@@ -4055,6 +4093,7 @@ test.arguments += --sys-no-query
cat cfg/box-1.0.0/build/config.build >>~%EOO%;
%.*
config.box.backend = libbiz
+ %.*
EOO
$pkg_drop box;
@@ -4095,6 +4134,7 @@ test.arguments += --sys-no-query
cat cfg/box-1.0.0/build/config.build >>~%EOO%;
%.*
config.box.backend = libbox
+ %.*
EOO
# Downgrade libbaz to reconfigure box and make sure we still keep
@@ -4130,6 +4170,7 @@ test.arguments += --sys-no-query
cat cfg/box-1.0.0/build/config.build >>~%EOO%;
%.*
config.box.backend = libbox
+ %.*
EOO
# Make sure the decision is hold for downgraded dependency either.
@@ -4158,6 +4199,7 @@ test.arguments += --sys-no-query
cat cfg/box-1.0.0/build/config.build >>~%EOO%;
%.*
config.box.backend = libbox
+ %.*
EOO
$pkg_drop box;
@@ -14440,6 +14482,7 @@ test.arguments += --sys-no-query
+cp -r $src/libhello-1.0.0 ./libhello
+cat <<EOI >+libhello/build/root.build
config [bool] config.libhello.develop ?= false
+ config [bool] config.libhello.extras ?= false
if ($build.mode != 'skeleton')
text "develop=$config.libhello.develop"
EOI
@@ -14455,9 +14498,9 @@ test.arguments += --sys-no-query
$clone_cfg;
$* libhello 2>!; # Update after output directory change.
- # Use bogus configuration variable to trigger reconfiguration.
+ # Specify a configuration variable to trigger reconfiguration.
#
- $* config.libhello.bogus=true -- libhello 2>>~%EOE%
+ $* config.libhello.extras=true -- libhello 2>>~%EOE%
disfigured libhello/1.0.0
%.*: develop=true%
configured libhello/1.0.0
diff --git a/tests/pkg-configure.testscript b/tests/pkg-configure.testscript
index 2374460..8430cec 100644
--- a/tests/pkg-configure.testscript
+++ b/tests/pkg-configure.testscript
@@ -276,6 +276,11 @@ if ($posix && "$uid" != '0')
: dependency-management
:
{
+ # Remove the config.cxx variable override to avoid the 'dropping no longer
+ # used variable' warning.
+ #
+ test.arguments = $regex.filter_out_match($test.arguments, 'config.cxx=.*')
+
+$clone_cfg && $rep_add $rep/stable && $rep_fetch --trust-yes
: still-has-deps
@@ -420,6 +425,11 @@ if ($posix && "$uid" != '0')
: dependency-alternatives
:
{
+ # Remove the config.cxx variable override to avoid the 'dropping no longer
+ # used variable' warning.
+ #
+ test.arguments = $regex.filter_out_match($test.arguments, 'config.cxx=.*')
+
+$clone_root_cfg && $rep_add $rep/t8a && $rep_fetch --trust-yes
: multiple-dependencies