-
Notifications
You must be signed in to change notification settings - Fork 47
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e4d3dd3
commit 340407e
Showing
2 changed files
with
69 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
@dnf5 | ||
Feature: Repoquery tests working with files | ||
|
||
|
||
Scenario: list files in an rpm including files in filelists.xml | ||
Given I use repository "repoquery-files" | ||
When I execute dnf with args "repoquery a.x86_64 --files" | ||
Then the exit code is 0 | ||
And stdout is | ||
""" | ||
<REPOSYNC> | ||
/root-file | ||
/usr/bin/a-binary | ||
""" | ||
|
||
|
||
Scenario: list files using --queryformat in an rpm including files in filelists.xml | ||
Given I use repository "repoquery-files" | ||
When I execute dnf with args "repoquery a.x86_64 --qf %{{files}}" | ||
Then the exit code is 0 | ||
And stdout is | ||
""" | ||
<REPOSYNC> | ||
/root-file | ||
/usr/bin/a-binary | ||
""" | ||
|
||
|
||
Scenario: filter by file in primary.xml | ||
Given I use repository "repoquery-files" | ||
When I execute dnf with args "repoquery --file /usr/bin/a-binary" | ||
Then the exit code is 0 | ||
And stdout is | ||
""" | ||
<REPOSYNC> | ||
a-0:1.0-1.fc29.x86_64 | ||
""" | ||
|
||
|
||
Scenario: filter by file in filelists.xml | ||
Given I use repository "repoquery-files" | ||
When I execute dnf with args "repoquery --file /root-file" | ||
Then the exit code is 0 | ||
And stdout is | ||
""" | ||
<REPOSYNC> | ||
a-0:1.0-1.fc29.x86_64 | ||
""" |
21 changes: 21 additions & 0 deletions
21
dnf-behave-tests/fixtures/specs/repoquery-files/a-1.0-1.fc29.spec
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
Name: a | ||
Version: 1.0 | ||
Release: 1.fc29 | ||
Summary: Made up package | ||
|
||
License: GPLv3+ | ||
Url: None | ||
|
||
%description | ||
a description | ||
|
||
%install | ||
mkdir -p %{buildroot}%{_bindir} | ||
touch %{buildroot}%{_bindir}/a-binary | ||
touch %{buildroot}/root-file | ||
|
||
%files | ||
%{_bindir}/a-binary | ||
/root-file | ||
|
||
%changelog |