Skip to content

Commit

Permalink
Add test for repoquery on repository with xml:base
Browse files Browse the repository at this point in the history
  • Loading branch information
m-blaha authored and kontura committed Sep 25, 2024
1 parent 527df56 commit 2999203
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions dnf-behave-tests/dnf/repoquery/xml-base.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
Feature: dnf repoquery command on packages with xml:base

# https://github.com/rpm-software-management/dnf/issues/2130
Scenario: Repoquery --location for repository that have packages with xml:base
Given I copy repository "simple-base" for modification
And I copy repository "dnf-ci-thirdparty" for modification
And I use repository "simple-base"
And I generate repodata for repository "simple-base" with extra arguments "--baseurl https://the.xml.base.location/repo/"
And I execute "mergerepo_c --omit-baseurl --repo file://{context.dnf.repos[simple-base].path} --repo file://{context.dnf.repos[dnf-ci-thirdparty].path}" in "{context.dnf.installroot}"
And I configure a new repository "merged-repo" with
| key | value |
| baseurl | file://{context.dnf.installroot}/merged_repo |
And I drop repository "simple-base"
And I drop repository "dnf-ci-thirdparty"
# packages from merged-repo that originated from dnf-ci-thirdparty do not have xml:base
When I execute dnf with args "repoquery --location solveigs-song"
Then the exit code is 0
And stdout is
"""
<REPOSYNC>
file://{context.dnf.installroot}/merged_repo/src/solveigs-song-1.0-1.src.rpm
file://{context.dnf.installroot}/merged_repo/x86_64/solveigs-song-1.0-1.x86_64.rpm
"""
# packages from merged-repo that originated from simple-base repo have xml:base
When I execute dnf with args "repoquery --location labirinto"
Then the exit code is 0
And stdout is
"""
<REPOSYNC>
https://the.xml.base.location/repo/src/labirinto-1.0-1.fc29.src.rpm
https://the.xml.base.location/repo/x86_64/labirinto-1.0-1.fc29.x86_64.rpm
"""

0 comments on commit 2999203

Please sign in to comment.