From fefeafa5725a08fed886474e2619cc7b4d091fd3 Mon Sep 17 00:00:00 2001 From: Mariana Ulaieva Date: Wed, 22 Jan 2020 13:26:48 +0100 Subject: [PATCH] Implement the Stream Expansion scenario --- tests/integration/example.test.env.yaml | 5 +++-- tests/integration/test_stream_expansion.py | 21 +++++++++++++++++++++ 2 files changed, 24 insertions(+), 2 deletions(-) create mode 100644 tests/integration/test_stream_expansion.py diff --git a/tests/integration/example.test.env.yaml b/tests/integration/example.test.env.yaml index 92a17080..d9733361 100644 --- a/tests/integration/example.test.env.yaml +++ b/tests/integration/example.test.env.yaml @@ -65,7 +65,8 @@ testdata: module: testmodule branch: test-no-components-branch stream_expansion: - # For this scenario it's necessary to use testmodule2 as a module and it doesn't make sense - # reusing a former build + # testmodule2 buildrequires and requires 2 streams from testmodule. + # These are expected to be built already. + # For this scenario reusing former builds doesn't make sense. module: testmodule2 branch: test-stream-expans-branch diff --git a/tests/integration/test_stream_expansion.py b/tests/integration/test_stream_expansion.py new file mode 100644 index 00000000..284d513d --- /dev/null +++ b/tests/integration/test_stream_expansion.py @@ -0,0 +1,21 @@ +# -*- coding: utf-8 -*- +# SPDX-License-Identifier: MIT + + +def test_stream_expansion(pkg_util, scenario, repo, koji): + """ + + Submit the testmodule2 build with `rhpkg-stage module-build` + The produced builds can be cancelled after the test cases have been verified to save on + resources and time + + Checks: + * Verify two module builds were generated from this build submission + + """ + repo.bump() + builds = pkg_util.run() + + assert len(builds) == 2 + for build in builds: + pkg_util.cancel(build)