From 1d85dec79e6b5dab3b1a7988f95603a8918e2993 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Fri, 26 Nov 2021 18:40:23 +0300 Subject: Add support for submitting for CI packages with non-standard version --- tests/ci.testscript | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/ci.testscript b/tests/ci.testscript index 2348cce..f048de0 100644 --- a/tests/ci.testscript +++ b/tests/ci.testscript @@ -40,7 +40,7 @@ g = git -C prj 2>! >&2 repository='http://example.com/prj.git' test.arguments += --yes --repository "$repository" --server "$server" \ ---simulate 'success' + --simulate 'success' config_cxx = cc config.cxx=$quote($recall($cxx.path) $cxx.config.mode, true) @@ -358,6 +358,35 @@ windows = ($cxx.target.class == 'windows') EOE } } + + : non-standard-version + : + : Test submitting a package with the non-standard version from a + : non-bdep-initialized project, using the forwarded build2 configuration. + : + { + cp --no-cleanup -pr ../../prj ./ &prj/***; + rm -r prj/.bdep/; + + sed -i -e 's/^(version:) .*$/\1 12345/' prj/manifest; + + sed -i \ + -e 's/^(project =.*)$/\1\nversion = 12345/' \ + -e 's/^using version$//' \ + prj/build/bootstrap.build; + + $g branch non-standard-version; + $g checkout non-standard-version; + $g -c core.safecrlf=false commit -a -m 'Change version'; + $g push --set-upstream origin non-standard-version; + + $build 'configure:' prj/@prj-cfg/,forward &prj/build/bootstrap/*** 2>!; + + $* --no-progress --forward 2>>~%EOE% + %CI request is queued.*% + %reference: .+% + EOE + } } : multi-pkg -- cgit v1.1