Index arch modulemd by full NSVC

There can be multiple modules with the same name and stream. They should
all have the same version, but will have different contexts. Fus takes
only N:S as input, but should pull in all matching modules. We just need
to give it correct data in the repo.

Signed-off-by: Lubomír Sedlář <lsedlar@redhat.com>
This commit is contained in:
Lubomír Sedlář 2018-09-05 08:51:38 +02:00
parent fbb739ef17
commit 1350684c31
5 changed files with 36 additions and 18 deletions

View file

@ -46,7 +46,7 @@ class TestGatherSourceModule(helpers.PungiTestCase):
self.assertEqual(len(groups), 0)
variant = self.compose.variants["Server"]
arch_mmd = variant.arch_mmds["x86_64"]["testmodule-master"]
arch_mmd = variant.arch_mmds["x86_64"]["testmodule:master:1:2017"]
self.assertEqual(set(arch_mmd.get_rpm_artifacts().get()),
set(["pkg-0:1.0.0-1.x86_64"]))
@ -63,7 +63,7 @@ class TestGatherSourceModule(helpers.PungiTestCase):
self.assertEqual(len(groups), 0)
variant = self.compose.variants["Server"]
arch_mmd = variant.arch_mmds["x86_64"]["testmodule-master"]
arch_mmd = variant.arch_mmds["x86_64"]["testmodule:master:1:2017"]
self.assertEqual(set(arch_mmd.get_rpm_artifacts().get()),
set(["pkg-0:1.0.0-1.x86_64", "pkg-0:1.0.0-1.i686"]))
@ -78,5 +78,5 @@ class TestGatherSourceModule(helpers.PungiTestCase):
self.assertEqual(len(groups), 0)
variant = self.compose.variants["Server"]
arch_mmd = variant.arch_mmds["x86_64"]["testmodule-master"]
arch_mmd = variant.arch_mmds["x86_64"]["testmodule:master:1:2017"]
self.assertEqual(len(arch_mmd.get_rpm_artifacts().get()), 0)