Skip to content

Commit

Permalink
createrepo_c: update test to new groupfile unification
Browse files Browse the repository at this point in the history
  • Loading branch information
kontura authored and Conan-Kudo committed Jul 18, 2023
1 parent f6547b3 commit a1fe36a
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 42 deletions.
3 changes: 1 addition & 2 deletions dnf-behave-tests/createrepo_c/compression.feature
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,7 @@ Given I create file "/groupfile.xml" with
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_zstd | ${checksum}-groupfile.xml.gz | sha256 | gz |
| group | ${checksum}-groupfile.xml.gz | sha256 | gz |
And primary in "/repodata/" doesn't have any packages


Expand Down
36 changes: 12 additions & 24 deletions dnf-behave-tests/createrepo_c/empty-repository.feature
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,7 @@ Scenario: Repo with --groupfile
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_gz | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml.zst | sha256 | zstd |


Scenario: Repo with --groupfile and --checksum sha
Expand All @@ -83,8 +82,7 @@ Scenario: Repo with --groupfile and --checksum sha
| primary | ${checksum}-primary.xml.zst | sha224 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha224 | zstd |
| other | ${checksum}-other.xml.zst | sha224 | zstd |
| group | ${checksum}-groupfile.xml | sha224 | - |
| group_gz | ${checksum}-groupfile.xml.zst | sha224 | zstd |
| group | ${checksum}-groupfile.xml.zst | sha224 | zstd |


Scenario: Repo with --simple-md-filenames and --groupfile
Expand All @@ -96,8 +94,7 @@ Scenario: Repo with --simple-md-filenames and --groupfile
| primary | primary.xml.zst | sha256 | zstd |
| filelists | filelists.xml.zst | sha256 | zstd |
| other | other.xml.zst | sha256 | zstd |
| group | groupfile.xml | sha256 | - |
| group_gz | groupfile.xml.zst | sha256 | zstd |
| group | groupfile.xml.zst | sha256 | zstd |


Scenario: Repo with --unique-md-filenames and --groupfile
Expand All @@ -109,8 +106,7 @@ Scenario: Repo with --unique-md-filenames and --groupfile
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_gz | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml.zst | sha256 | zstd |


Scenario: Repo with --xz compression and --groupfile
Expand All @@ -122,8 +118,7 @@ Scenario: Repo with --xz compression and --groupfile
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_xz | ${checksum}-groupfile.xml.xz | sha256 | xz |
| group | ${checksum}-groupfile.xml.xz | sha256 | xz |


Scenario: Repo with --compress-type bz2 and --groupfile
Expand All @@ -135,8 +130,7 @@ Scenario: Repo with --compress-type bz2 and --groupfile
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_bz2 | ${checksum}-groupfile.xml.bz2 | sha256 | bz2 |
| group | ${checksum}-groupfile.xml.bz2 | sha256 | bz2 |


Scenario: Repo with --compress-type gz
Expand All @@ -148,8 +142,7 @@ Scenario: Repo with --compress-type gz
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_gz | ${checksum}-groupfile.xml.gz | sha256 | gz |
| group | ${checksum}-groupfile.xml.gz | sha256 | gz |


Scenario: Repo with --compress-type xz
Expand All @@ -161,8 +154,7 @@ Scenario: Repo with --compress-type xz
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_xz | ${checksum}-groupfile.xml.xz | sha256 | xz |
| group | ${checksum}-groupfile.xml.xz | sha256 | xz |


Scenario: Repo with --repomd-checksum and --groupfile
Expand All @@ -174,8 +166,7 @@ Scenario: Repo with --repomd-checksum and --groupfile
| primary | ${checksum}-primary.xml.zst | sha224 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha224 | zstd |
| other | ${checksum}-other.xml.zst | sha224 | zstd |
| group | ${checksum}-groupfile.xml | sha224 | - |
| group_gz | ${checksum}-groupfile.xml.zst | sha224 | zstd |
| group | ${checksum}-groupfile.xml.zst | sha224 | zstd |


Scenario: Repo with --checksum --repomd-checksum and --groupfile
Expand All @@ -187,8 +178,7 @@ Scenario: Repo with --checksum --repomd-checksum and --groupfile
| primary | ${checksum}-primary.xml.zst | sha512 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha512 | zstd |
| other | ${checksum}-other.xml.zst | sha512 | zstd |
| group | ${checksum}-groupfile.xml | sha512 | - |
| group_gz | ${checksum}-groupfile.xml.zst | sha512 | zstd |
| group | ${checksum}-groupfile.xml.zst | sha512 | zstd |


Scenario: Repo with --general-compress-type and --groupfile
Expand All @@ -200,8 +190,7 @@ Scenario: Repo with --general-compress-type and --groupfile
| primary | ${checksum}-primary.xml.xz | sha256 | xz |
| filelists | ${checksum}-filelists.xml.xz | sha256 | xz |
| other | ${checksum}-other.xml.xz | sha256 | xz |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_xz | ${checksum}-groupfile.xml.xz | sha256 | xz |
| group | ${checksum}-groupfile.xml.xz | sha256 | xz |


Scenario: Repo without compression and --groupfile
Expand All @@ -213,8 +202,7 @@ Scenario: Repo without compression and --groupfile
| primary | ${checksum}-primary.xml.xz | sha256 | xz |
| filelists | ${checksum}-filelists.xml.xz | sha256 | xz |
| other | ${checksum}-other.xml.xz | sha256 | xz |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_xz | ${checksum}-groupfile.xml.xz | sha256 | xz |
| group | ${checksum}-groupfile.xml.xz | sha256 | xz |


Scenario: Repo from empty directory with --distro DISTRO-TAG
Expand Down
21 changes: 7 additions & 14 deletions dnf-behave-tests/createrepo_c/update-keep-all-metadata.feature
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,7 @@ Given I execute createrepo_c with args "--groupfile ../groupfile.xml ." in "/tem
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_gz | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml.zst | sha256 | zstd |
When I execute createrepo_c with args "--update --discard-additional-metadata ." in "/temp-repo"
Then the exit code is 0
And repodata "/temp-repo/repodata/" are consistent
Expand All @@ -89,8 +88,7 @@ Given I execute createrepo_c with args "--groupfile ../groupfile.xml ." in "/tem
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_gz | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| updateinfo | ${checksum}-updateinfo.xml.zst | sha256 | zstd |
| custom_metadata | ${checksum}-custom_metadata.txt.zst| sha256 | zstd |
| modules | ${checksum}-modules.yaml.zst | sha256 | zstd |
Expand All @@ -107,8 +105,7 @@ Given I execute createrepo_c with args "--groupfile ../groupfile.xml ." in "/tem
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile2.xml | sha256 | - |
| group_gz | ${checksum}-groupfile2.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile2.xml.zst | sha256 | zstd |
| custom_metadata | ${checksum}-custom_metadata.txt.zst| sha256 | zstd |


Expand All @@ -128,8 +125,7 @@ Given I execute createrepo_c with args "--groupfile ../groupfile.xml ." in "/tem
| filelists_zck | ${checksum}-filelists.xml.zck | sha256 | zck |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| other_zck | ${checksum}-other.xml.zck | sha256 | zck |
| group | ${checksum}-groupfile2.xml | sha256 | - |
| group_gz | ${checksum}-groupfile2.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile2.xml.zst | sha256 | zstd |
| group_zck | ${checksum}-groupfile2.xml.zck | sha256 | zck |
| custom_metadata | ${checksum}-custom_metadata.txt.zst | sha256 | zstd |
| custom_metadata_zck | ${checksum}-custom_metadata.txt.zck | sha256 | zck |
Expand All @@ -148,8 +144,7 @@ Given I execute createrepo_c with args "--groupfile ../groupfile.xml --zck ." in
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_gz | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| group_zck | ${checksum}-groupfile.xml.zck | sha256 | zck |
| custom_metadata | ${checksum}-custom_metadata.txt.zst | sha256 | zstd |
| custom_metadata_zck | ${checksum}-custom_metadata.txt.zck | sha256 | zck |
Expand Down Expand Up @@ -198,8 +193,7 @@ Given I execute createrepo_c with args "--groupfile ../groupfile.xml ." in "/tem
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_gz | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| updateinfo | ${checksum}-updateinfo.xml.zst | sha256 | zstd |
| custom_metadata | ${checksum}-custom_metadata.txt.zst| sha256 | zstd |
| modules | ${checksum}-modules.yaml.zst | sha256 | zstd |
Expand Down Expand Up @@ -285,6 +279,5 @@ Given I execute createrepo_c with args "--groupfile ../groupfile.xml ." in "/tem
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_gz | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| custom_metadata | ${checksum}-custom_metadata.txt.zst | sha256 | zstd |
3 changes: 1 addition & 2 deletions dnf-behave-tests/createrepo_c/update.feature
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,7 @@ Given I create directory "/empty-repo/"
| primary | ${checksum}-primary.xml.zst | sha256 | zstd |
| filelists | ${checksum}-filelists.xml.zst | sha256 | zstd |
| other | ${checksum}-other.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml | sha256 | - |
| group_zst | ${checksum}-groupfile.xml.zst | sha256 | zstd |
| group | ${checksum}-groupfile.xml.zst | sha256 | zstd |
When I execute createrepo_c with args "--update ." in "/empty-repo"
Then the exit code is 0
And repodata "/empty-repo/repodata/" are consistent
Expand Down

0 comments on commit a1fe36a

Please sign in to comment.