hammer_cli_katello 1.11.1 → 1.11.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/hammer_cli_katello/capsule.rb +1 -1
- data/lib/hammer_cli_katello/version.rb +1 -1
- data/test/functional/capsule/content/data/sync_status_no_counts.json +6 -0
- data/test/functional/capsule/content/info_test.rb +43 -0
- data/test/functional/content_view/version/republish_repositories_test.rb +1 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2a0bb232e9b8a0584ba860f898664e6a36817703793cd4fabe1538c06e899efc
|
4
|
+
data.tar.gz: fbade16a47cee20fa65a9abbcfefb77b8811e0d091547d366bfe8a027531c819
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6b535f374bfecfa675fe4dad827fc395eae0c013c829b1106b92776f71284cf06db6f5160330fe49e29345939670552b54de67c3ee2d481aa063c436a952d373
|
7
|
+
data.tar.gz: 42efbf0e089b7b1dad5b4d48104a0aa081c9afb731f8e34875262d3f6eabb57b90480ffbb106526a39a6d901d41631635b4f15521bfc54262e84edbf287eb364
|
@@ -218,7 +218,7 @@ module HammerCLIKatello
|
|
218
218
|
data["lifecycle_environments"].each do |lce|
|
219
219
|
lce["content_views"].each do |cv|
|
220
220
|
cv["repositories"].each do |repo|
|
221
|
-
if cv["up_to_date"]
|
221
|
+
if cv["up_to_date"] && !data.dig("content_counts").nil?
|
222
222
|
cvv_count_repos = data.dig("content_counts", "content_view_versions",
|
223
223
|
cv["cvv_id"].to_s, "repositories")
|
224
224
|
cvv_count_repos.each do |_repo_id, counts_and_metadata|
|
@@ -53,6 +53,49 @@ describe 'capsule content info' do
|
|
53
53
|
assert_cmd(expected_result, result)
|
54
54
|
end
|
55
55
|
|
56
|
+
it "works with no content counts" do
|
57
|
+
@sync_status = load_json('./data/sync_status_no_counts.json', __FILE__)
|
58
|
+
@sync_status['lifecycle_environments'] = [
|
59
|
+
load_json('./data/library_env.json', __FILE__),
|
60
|
+
load_json('./data/unsynced_env.json', __FILE__)
|
61
|
+
]
|
62
|
+
|
63
|
+
ex = api_expects(:capsule_content, :sync_status, 'Get sync info') do |par|
|
64
|
+
par['id'] == 3
|
65
|
+
end
|
66
|
+
ex.returns(@sync_status)
|
67
|
+
|
68
|
+
output = OutputMatcher.new([
|
69
|
+
"Lifecycle Environments:",
|
70
|
+
" 1) Name: Library",
|
71
|
+
" Organization: Default Organization",
|
72
|
+
" Content Views:",
|
73
|
+
" 1) Name: Zoo View",
|
74
|
+
" Composite: no",
|
75
|
+
" Last Published: 2023/10/09 19:18:15",
|
76
|
+
" Repositories:",
|
77
|
+
" 1) Repository ID: 2",
|
78
|
+
" Repository Name: Zoo",
|
79
|
+
" Content Counts:",
|
80
|
+
" Warning: Content view must be synced to see content counts",
|
81
|
+
" 2) Name: Test",
|
82
|
+
" Organization: Default Organization",
|
83
|
+
" Content Views:",
|
84
|
+
" 1) Name: Zoo View",
|
85
|
+
" Composite: no",
|
86
|
+
" Last Published: 2023/10/09 19:18:15",
|
87
|
+
" Repositories:",
|
88
|
+
" 1) Repository ID: 2",
|
89
|
+
" Repository Name: Zoo",
|
90
|
+
" Content Counts:",
|
91
|
+
" Warning: Content view must be synced to see content counts"
|
92
|
+
])
|
93
|
+
expected_result = success_result(output)
|
94
|
+
|
95
|
+
result = run_cmd(@cmd + params)
|
96
|
+
assert_cmd(expected_result, result)
|
97
|
+
end
|
98
|
+
|
56
99
|
it "resolves id from name" do
|
57
100
|
params = ['--name=capsule1']
|
58
101
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hammer_cli_katello
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.11.
|
4
|
+
version: 1.11.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adam Price
|
@@ -37,7 +37,7 @@ authors:
|
|
37
37
|
autorequire:
|
38
38
|
bindir: bin
|
39
39
|
cert_chain: []
|
40
|
-
date:
|
40
|
+
date: 2024-02-16 00:00:00.000000000 Z
|
41
41
|
dependencies:
|
42
42
|
- !ruby/object:Gem::Dependency
|
43
43
|
name: hammer_cli_foreman
|
@@ -435,6 +435,7 @@ files:
|
|
435
435
|
- test/functional/capsule/content/capsule_content_helpers.rb
|
436
436
|
- test/functional/capsule/content/data/library_env.json
|
437
437
|
- test/functional/capsule/content/data/sync_status.json
|
438
|
+
- test/functional/capsule/content/data/sync_status_no_counts.json
|
438
439
|
- test/functional/capsule/content/data/sync_tasks.json
|
439
440
|
- test/functional/capsule/content/data/unsynced_env.json
|
440
441
|
- test/functional/capsule/content/info_test.rb
|
@@ -675,6 +676,7 @@ test_files:
|
|
675
676
|
- test/functional/capsule/content/capsule_content_helpers.rb
|
676
677
|
- test/functional/capsule/content/data/library_env.json
|
677
678
|
- test/functional/capsule/content/data/sync_status.json
|
679
|
+
- test/functional/capsule/content/data/sync_status_no_counts.json
|
678
680
|
- test/functional/capsule/content/data/sync_tasks.json
|
679
681
|
- test/functional/capsule/content/data/unsynced_env.json
|
680
682
|
- test/functional/capsule/content/info_test.rb
|