Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add test for --transient and persistence option #1618

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 36 additions & 0 deletions dnf-behave-tests/dnf/transient.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
Feature: Persistence option and --transient


Scenario: Try installing a package using --transient on a non-bootc system
Given I use repository "dnf-ci-fedora"
When I execute dnf with args "install flac --transient"
Then the exit code is 1
And stderr is
"""
Transient transactions are only supported on bootc systems.
"""

Scenario: Try installing a package with persistence=transient on a non-bootc system
Given I use repository "dnf-ci-fedora"
When I execute dnf with args "install flac --setopt=persistence=transient"
Then the exit code is 1
And stderr is
"""
Transient transactions are only supported on bootc systems.
"""

Scenario: Install a package with persistence=auto on a non-bootc system
Given I use repository "dnf-ci-fedora"
When I execute dnf with args "install flac --setopt=persistence=auto"
Then the exit code is 0
And Transaction is following
| Action | Package |
| install | flac-0:1.3.2-8.fc29.x86_64 |

Scenario: Install a package with persistence=persist on a non-bootc system
Given I use repository "dnf-ci-fedora"
When I execute dnf with args "install flac --setopt=persistence=persist"
Then the exit code is 0
And Transaction is following
| Action | Package |
| install | flac-0:1.3.2-8.fc29.x86_64 |
Loading