lita-pulp 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (28) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +18 -0
  3. data/Gemfile +3 -0
  4. data/README.md +35 -0
  5. data/Rakefile +8 -0
  6. data/lib/lita-pulp.rb +15 -0
  7. data/lib/lita/handlers/pulp.rb +369 -0
  8. data/lib/pulphelper/misc.rb +16 -0
  9. data/lib/pulphelper/repo.rb +356 -0
  10. data/lib/pulphelper/unit.rb +107 -0
  11. data/lita-pulp.gemspec +28 -0
  12. data/locales/en.yml +23 -0
  13. data/spec/fixtures/cassettes/Lita_Handlers_Pulp/_copy_puppet_between_repo/copy_puppet_module.yml +86 -0
  14. data/spec/fixtures/cassettes/Lita_Handlers_Pulp/_copy_puppet_between_repo/copy_puppet_module_delete_new_and_publish.yml +217 -0
  15. data/spec/fixtures/cassettes/Lita_Handlers_Pulp/_copy_rpm_between_repo/copy_rpm_package.yml +86 -0
  16. data/spec/fixtures/cassettes/Lita_Handlers_Pulp/_copy_rpm_between_repo/copy_rpm_package_delete_new_and_publish.yml +264 -0
  17. data/spec/fixtures/cassettes/Lita_Handlers_Pulp/_puppet_repos/list_puppet_repos.yml +88 -0
  18. data/spec/fixtures/cassettes/Lita_Handlers_Pulp/_puppet_search/search_puppet_with_repo.yml +134 -0
  19. data/spec/fixtures/cassettes/Lita_Handlers_Pulp/_puppet_search/search_puppet_without_author_name.yml +134 -0
  20. data/spec/fixtures/cassettes/Lita_Handlers_Pulp/_puppet_search/search_puppet_without_repo.yml +134 -0
  21. data/spec/fixtures/cassettes/Lita_Handlers_Pulp/_rpm_repos/list_rpm_repos.yml +593 -0
  22. data/spec/fixtures/cassettes/Lita_Handlers_Pulp/_rpm_search/search_rpm_with_repo.yml +152 -0
  23. data/spec/fixtures/cassettes/Lita_Handlers_Pulp/_rpm_search/search_rpm_without_repo.yml +152 -0
  24. data/spec/lita/handlers/pulp_repo_spec.rb +35 -0
  25. data/spec/lita/handlers/pulp_unit_spec.rb +79 -0
  26. data/spec/spec_helper.rb +28 -0
  27. data/templates/.gitkeep +0 -0
  28. metadata +226 -0
@@ -0,0 +1,152 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: https://pulp.co.epi.web/pulp/api/v2/content/units/rpm/search/
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"criteria":{"fields":["name","version","release","epoch","checksum"],"filters":{"name":{"$regex":"cosmos"}},"sort":[["epoch","descending"],["version","descending"],["release","descending"]]},"include_repos":true}'
9
+ headers:
10
+ Accept:
11
+ - application/json
12
+ Accept-Encoding:
13
+ - gzip, deflate
14
+ Content-Type:
15
+ - application/json
16
+ Content-Length:
17
+ - '213'
18
+ User-Agent:
19
+ - Ruby
20
+ Authorization:
21
+ - Basic YWRtaW46YWRtaW4=
22
+ response:
23
+ status:
24
+ code: 200
25
+ message: OK
26
+ headers:
27
+ Date:
28
+ - Wed, 29 Jun 2016 14:43:57 GMT
29
+ Server:
30
+ - Apache/2.2.15 (CentOS)
31
+ Content-Length:
32
+ - '10671'
33
+ Connection:
34
+ - close
35
+ Content-Type:
36
+ - application/json; charset=utf-8
37
+ body:
38
+ encoding: UTF-8
39
+ string: '[{"repository_memberships": ["ent-cent7-qa", "ent-cent7-dev"], "name":
40
+ "cosmos-web", "checksum": "8c0b75af5ec12395ff2b7700322aa9e9287fc44ca7f474e5e6edc6bc632df2e5",
41
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160627.211338.63",
42
+ "_id": "c3dcddf1-3d2f-4387-b06d-0f13076c2e08", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/c3dcddf1-3d2f-4387-b06d-0f13076c2e08/"},
43
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
44
+ "73f8d21e0192945f923e692e3f900db11a99ee84afb1549b1262f05dc2279b81", "epoch":
45
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160623.151418.62", "_id":
46
+ "f6767690-ede5-4559-af25-5d870c768bed", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/f6767690-ede5-4559-af25-5d870c768bed/"},
47
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
48
+ "8e63ece6b5cfc6a75c5218f952b4782984ef27efa20c7bc1565f08ed8a7e45e4", "epoch":
49
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160621.152704.61", "_id":
50
+ "9a7ebaac-a355-4aa5-b2a0-9d6cd0aa02a1", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/9a7ebaac-a355-4aa5-b2a0-9d6cd0aa02a1/"},
51
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
52
+ "d266fb7362773ba11ccbdf9f79319ed2fdf582154c6e2f8e24ef20424904008f", "epoch":
53
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160620.210654.60", "_id":
54
+ "0cc928ef-c620-40a0-b041-710cdcfd755b", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/0cc928ef-c620-40a0-b041-710cdcfd755b/"},
55
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
56
+ "2b3f812bff3841cff11ed5c831b8ccbacce2bcedc28dc7ba8e5d0aed7fa43ad0", "epoch":
57
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160620.190123.59", "_id":
58
+ "631ce1de-f252-43b5-a6ee-92af46432f49", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/631ce1de-f252-43b5-a6ee-92af46432f49/"},
59
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
60
+ "3dd4eef1765372e1d7a61acb101fa31c6c73efb16def4132c47b43c614d5f411", "epoch":
61
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160616.211020.58", "_id":
62
+ "f7624c3d-a987-46de-aa9b-6ae5e0e01422", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/f7624c3d-a987-46de-aa9b-6ae5e0e01422/"},
63
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
64
+ "a071fdf98fe5e63f04f0b35156134b5f930a022041eed37a1d5f59f2ef38902c", "epoch":
65
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160616.191517.57", "_id":
66
+ "21bf34f3-32df-4618-9538-0b31aa1b6bb1", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/21bf34f3-32df-4618-9538-0b31aa1b6bb1/"},
67
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
68
+ "c8cf31ff286995d2b2c36851fbf00ed6ab5cdaad4bf216282e192a52892d6b61", "epoch":
69
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160616.155408.56", "_id":
70
+ "b13c8831-65bb-4c9a-9882-12f2c419d33d", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/b13c8831-65bb-4c9a-9882-12f2c419d33d/"},
71
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
72
+ "acd1c76469a3c8d897538fc0a42695d3d5fc592f0a5d96e98aeb71977a87c1e5", "epoch":
73
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160616.122523.55", "_id":
74
+ "a86ab523-d8a3-42c3-ab86-b0e4e28219cc", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/a86ab523-d8a3-42c3-ab86-b0e4e28219cc/"},
75
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
76
+ "b4c59def1e247224c032d39fca9e875798a8b40493b1114a50dfa9bf7efd70db", "epoch":
77
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160616.120215.54", "_id":
78
+ "63c849e8-1bf0-442e-a14b-7eb23d3e7bbb", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/63c849e8-1bf0-442e-a14b-7eb23d3e7bbb/"},
79
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
80
+ "6e1d0577e02ec10bfc0bab585af2f85445b9159c31e7726c1988546b10114fbd", "epoch":
81
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160614.222549.53", "_id":
82
+ "fa294815-2bca-4fba-957e-6317de984736", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/fa294815-2bca-4fba-957e-6317de984736/"},
83
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
84
+ "34b6e3205a70441c76bc66130b70d18cf512cffdc24027c0b8b94fe7ef153746", "epoch":
85
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160609.150824.52", "_id":
86
+ "4e909ab9-9a92-4fe3-a2b3-85a2bb56c7fc", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/4e909ab9-9a92-4fe3-a2b3-85a2bb56c7fc/"},
87
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
88
+ "eac1d6e95b05410835657241077214a11db580e5bc13458b13d09f6deaaa103d", "epoch":
89
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160606.194020.51", "_id":
90
+ "0f111a86-eae1-45dd-aa6e-a8f86a88fe3e", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/0f111a86-eae1-45dd-aa6e-a8f86a88fe3e/"},
91
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
92
+ "734ac412e5eda9475e0149a7807a4c461d14f9c3a6d4f9e5d5d9bd922f6f398c", "epoch":
93
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160523.155042.50", "_id":
94
+ "76eaaec4-21a9-4597-ac56-b8d4b79598aa", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/76eaaec4-21a9-4597-ac56-b8d4b79598aa/"},
95
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
96
+ "51c9cb76e90f3d4fb063d9a77a676f6ce07ab7a4196f8a8cf88613f9eb541366", "epoch":
97
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160519.180243.49", "_id":
98
+ "536dd4ee-0f33-4e1a-9336-bce2a7fd0e69", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/536dd4ee-0f33-4e1a-9336-bce2a7fd0e69/"},
99
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
100
+ "284d44bae53b9a553d206dba501e9390ffebb14874331d5e11037d7110cefc11", "epoch":
101
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160518.143149.45", "_id":
102
+ "c0340f24-0f2a-4430-9433-44e62bb2484c", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/c0340f24-0f2a-4430-9433-44e62bb2484c/"},
103
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
104
+ "962acd4fdfed293e5476f24dcb371c6bb8f87df48a3b4ef5753854f9b591c3d0", "epoch":
105
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160518.142908.44", "_id":
106
+ "67e32b5d-6711-4245-aa1c-28d679871f18", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/67e32b5d-6711-4245-aa1c-28d679871f18/"},
107
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
108
+ "58ed5ceaba8ce81a2b7fa27eaa0ccb69db84cac930b3f376f23397a3a47d69a9", "epoch":
109
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160518.142607.43", "_id":
110
+ "3f816e8e-4807-4c7a-ba7f-7c037aec20ca", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/3f816e8e-4807-4c7a-ba7f-7c037aec20ca/"},
111
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
112
+ "44f22f7587692e73da698e658ad3b369e7deb98d3d555898a5c488362319d3dc", "epoch":
113
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160518.142225.42", "_id":
114
+ "d7faf0c1-9d34-46dd-8643-89b50818f8f7", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/d7faf0c1-9d34-46dd-8643-89b50818f8f7/"},
115
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
116
+ "eaa26d72513ea8a2b89dff2f5de90e2937b6f0265c09d16fa20cbe6607c26c51", "epoch":
117
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160516.215104.41", "_id":
118
+ "4fd000fd-8184-4a76-a2b0-233871b4a91f", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/4fd000fd-8184-4a76-a2b0-233871b4a91f/"},
119
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
120
+ "57c2f4dcd2fc2cf5b6b9f09b36193e5428e2b721dbc3ac79b326bcb07d8980e2", "epoch":
121
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160512.213034.40", "_id":
122
+ "a21512fe-b642-4c9c-bfb3-08283309dc44", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/a21512fe-b642-4c9c-bfb3-08283309dc44/"},
123
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
124
+ "5373e8dd2f712c63580d406277a75e29afcfa8f3ef21cdb587e9768440c8dbd7", "epoch":
125
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160512.142820.39", "_id":
126
+ "a939f53d-520c-4155-878e-1dade5028ddc", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/a939f53d-520c-4155-878e-1dade5028ddc/"},
127
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
128
+ "d0c45de8f7197290b0c3a49e73bdf2c07a531075832bdb267bab9d3f4225063c", "epoch":
129
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160510.184328.37", "_id":
130
+ "45be0e53-039c-4709-a41f-1bc2b8f14444", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/45be0e53-039c-4709-a41f-1bc2b8f14444/"},
131
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
132
+ "97a8bf52ed37320aec4ddc064efc96f1d6ef85a2632a5fad358a4d6e35098eb4", "epoch":
133
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160506.213118.36", "_id":
134
+ "e5e9e688-4839-4f06-a62d-551d35fc404b", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/e5e9e688-4839-4f06-a62d-551d35fc404b/"},
135
+ {"repository_memberships": [], "name": "cosmos-web", "checksum": "8adee7c93e4ab1cf51bae44e8aea2bf60a41af5b45a8dad5cc0af3d308c260dc",
136
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160506.211252.34",
137
+ "_id": "9a956a24-92d3-4433-9dca-2bb8a0661b4b", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/9a956a24-92d3-4433-9dca-2bb8a0661b4b/"},
138
+ {"repository_memberships": [], "name": "cosmos-web", "checksum": "875669ec02058a780a4e5158950eb073e0ff5a79f332a2ac9bf5f5febb13144d",
139
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160503.211005.29",
140
+ "_id": "c958fcb8-db2c-4599-a667-bfaa3e576043", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/c958fcb8-db2c-4599-a667-bfaa3e576043/"},
141
+ {"repository_memberships": [], "name": "cosmos-web", "checksum": "84cd4e24d3539d6d9420678ffa6761c84f4fd3d85cb73bffb1fe3ca6d66317e0",
142
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160421.145308.28",
143
+ "_id": "580b409c-4c7a-4820-84e3-04aa9f493e0f", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/580b409c-4c7a-4820-84e3-04aa9f493e0f/"},
144
+ {"repository_memberships": [], "name": "cosmos-web", "checksum": "ede362149a45cbf9713710f3631411bc7bee60fc75b4090f7e0a6f26a126604e",
145
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160414.173925.27",
146
+ "_id": "c96e836c-57f4-4c4a-be23-70375bed4119", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/c96e836c-57f4-4c4a-be23-70375bed4119/"},
147
+ {"repository_memberships": [], "name": "cosmos-web", "checksum": "76b818acdbab231510892144d1f27d2ab775b8ba10d3ec249afdbec3fe0fb367",
148
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160331.072130.26",
149
+ "_id": "104d49a9-fdda-40f3-9c85-9bac91294738", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/104d49a9-fdda-40f3-9c85-9bac91294738/"}]'
150
+ http_version:
151
+ recorded_at: Wed, 29 Jun 2016 14:44:07 GMT
152
+ recorded_with: VCR 3.0.3
@@ -0,0 +1,152 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: https://pulp.co.epi.web/pulp/api/v2/content/units/rpm/search/
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"criteria":{"fields":["name","version","release","epoch","checksum"],"filters":{"name":{"$regex":"cosmos"}},"sort":[["epoch","descending"],["version","descending"],["release","descending"]]},"include_repos":true}'
9
+ headers:
10
+ Accept:
11
+ - application/json
12
+ Accept-Encoding:
13
+ - gzip, deflate
14
+ Content-Type:
15
+ - application/json
16
+ Content-Length:
17
+ - '213'
18
+ User-Agent:
19
+ - Ruby
20
+ Authorization:
21
+ - Basic YWRtaW46YWRtaW4=
22
+ response:
23
+ status:
24
+ code: 200
25
+ message: OK
26
+ headers:
27
+ Date:
28
+ - Wed, 29 Jun 2016 14:43:56 GMT
29
+ Server:
30
+ - Apache/2.2.15 (CentOS)
31
+ Content-Length:
32
+ - '10671'
33
+ Connection:
34
+ - close
35
+ Content-Type:
36
+ - application/json; charset=utf-8
37
+ body:
38
+ encoding: UTF-8
39
+ string: '[{"repository_memberships": ["ent-cent7-qa", "ent-cent7-dev"], "name":
40
+ "cosmos-web", "checksum": "8c0b75af5ec12395ff2b7700322aa9e9287fc44ca7f474e5e6edc6bc632df2e5",
41
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160627.211338.63",
42
+ "_id": "c3dcddf1-3d2f-4387-b06d-0f13076c2e08", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/c3dcddf1-3d2f-4387-b06d-0f13076c2e08/"},
43
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
44
+ "73f8d21e0192945f923e692e3f900db11a99ee84afb1549b1262f05dc2279b81", "epoch":
45
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160623.151418.62", "_id":
46
+ "f6767690-ede5-4559-af25-5d870c768bed", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/f6767690-ede5-4559-af25-5d870c768bed/"},
47
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
48
+ "8e63ece6b5cfc6a75c5218f952b4782984ef27efa20c7bc1565f08ed8a7e45e4", "epoch":
49
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160621.152704.61", "_id":
50
+ "9a7ebaac-a355-4aa5-b2a0-9d6cd0aa02a1", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/9a7ebaac-a355-4aa5-b2a0-9d6cd0aa02a1/"},
51
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
52
+ "d266fb7362773ba11ccbdf9f79319ed2fdf582154c6e2f8e24ef20424904008f", "epoch":
53
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160620.210654.60", "_id":
54
+ "0cc928ef-c620-40a0-b041-710cdcfd755b", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/0cc928ef-c620-40a0-b041-710cdcfd755b/"},
55
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
56
+ "2b3f812bff3841cff11ed5c831b8ccbacce2bcedc28dc7ba8e5d0aed7fa43ad0", "epoch":
57
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160620.190123.59", "_id":
58
+ "631ce1de-f252-43b5-a6ee-92af46432f49", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/631ce1de-f252-43b5-a6ee-92af46432f49/"},
59
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
60
+ "3dd4eef1765372e1d7a61acb101fa31c6c73efb16def4132c47b43c614d5f411", "epoch":
61
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160616.211020.58", "_id":
62
+ "f7624c3d-a987-46de-aa9b-6ae5e0e01422", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/f7624c3d-a987-46de-aa9b-6ae5e0e01422/"},
63
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
64
+ "a071fdf98fe5e63f04f0b35156134b5f930a022041eed37a1d5f59f2ef38902c", "epoch":
65
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160616.191517.57", "_id":
66
+ "21bf34f3-32df-4618-9538-0b31aa1b6bb1", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/21bf34f3-32df-4618-9538-0b31aa1b6bb1/"},
67
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
68
+ "c8cf31ff286995d2b2c36851fbf00ed6ab5cdaad4bf216282e192a52892d6b61", "epoch":
69
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160616.155408.56", "_id":
70
+ "b13c8831-65bb-4c9a-9882-12f2c419d33d", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/b13c8831-65bb-4c9a-9882-12f2c419d33d/"},
71
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
72
+ "acd1c76469a3c8d897538fc0a42695d3d5fc592f0a5d96e98aeb71977a87c1e5", "epoch":
73
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160616.122523.55", "_id":
74
+ "a86ab523-d8a3-42c3-ab86-b0e4e28219cc", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/a86ab523-d8a3-42c3-ab86-b0e4e28219cc/"},
75
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
76
+ "b4c59def1e247224c032d39fca9e875798a8b40493b1114a50dfa9bf7efd70db", "epoch":
77
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160616.120215.54", "_id":
78
+ "63c849e8-1bf0-442e-a14b-7eb23d3e7bbb", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/63c849e8-1bf0-442e-a14b-7eb23d3e7bbb/"},
79
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
80
+ "6e1d0577e02ec10bfc0bab585af2f85445b9159c31e7726c1988546b10114fbd", "epoch":
81
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160614.222549.53", "_id":
82
+ "fa294815-2bca-4fba-957e-6317de984736", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/fa294815-2bca-4fba-957e-6317de984736/"},
83
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
84
+ "34b6e3205a70441c76bc66130b70d18cf512cffdc24027c0b8b94fe7ef153746", "epoch":
85
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160609.150824.52", "_id":
86
+ "4e909ab9-9a92-4fe3-a2b3-85a2bb56c7fc", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/4e909ab9-9a92-4fe3-a2b3-85a2bb56c7fc/"},
87
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
88
+ "eac1d6e95b05410835657241077214a11db580e5bc13458b13d09f6deaaa103d", "epoch":
89
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160606.194020.51", "_id":
90
+ "0f111a86-eae1-45dd-aa6e-a8f86a88fe3e", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/0f111a86-eae1-45dd-aa6e-a8f86a88fe3e/"},
91
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
92
+ "734ac412e5eda9475e0149a7807a4c461d14f9c3a6d4f9e5d5d9bd922f6f398c", "epoch":
93
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160523.155042.50", "_id":
94
+ "76eaaec4-21a9-4597-ac56-b8d4b79598aa", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/76eaaec4-21a9-4597-ac56-b8d4b79598aa/"},
95
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
96
+ "51c9cb76e90f3d4fb063d9a77a676f6ce07ab7a4196f8a8cf88613f9eb541366", "epoch":
97
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160519.180243.49", "_id":
98
+ "536dd4ee-0f33-4e1a-9336-bce2a7fd0e69", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/536dd4ee-0f33-4e1a-9336-bce2a7fd0e69/"},
99
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
100
+ "284d44bae53b9a553d206dba501e9390ffebb14874331d5e11037d7110cefc11", "epoch":
101
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160518.143149.45", "_id":
102
+ "c0340f24-0f2a-4430-9433-44e62bb2484c", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/c0340f24-0f2a-4430-9433-44e62bb2484c/"},
103
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
104
+ "962acd4fdfed293e5476f24dcb371c6bb8f87df48a3b4ef5753854f9b591c3d0", "epoch":
105
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160518.142908.44", "_id":
106
+ "67e32b5d-6711-4245-aa1c-28d679871f18", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/67e32b5d-6711-4245-aa1c-28d679871f18/"},
107
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
108
+ "58ed5ceaba8ce81a2b7fa27eaa0ccb69db84cac930b3f376f23397a3a47d69a9", "epoch":
109
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160518.142607.43", "_id":
110
+ "3f816e8e-4807-4c7a-ba7f-7c037aec20ca", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/3f816e8e-4807-4c7a-ba7f-7c037aec20ca/"},
111
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
112
+ "44f22f7587692e73da698e658ad3b369e7deb98d3d555898a5c488362319d3dc", "epoch":
113
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160518.142225.42", "_id":
114
+ "d7faf0c1-9d34-46dd-8643-89b50818f8f7", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/d7faf0c1-9d34-46dd-8643-89b50818f8f7/"},
115
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
116
+ "eaa26d72513ea8a2b89dff2f5de90e2937b6f0265c09d16fa20cbe6607c26c51", "epoch":
117
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160516.215104.41", "_id":
118
+ "4fd000fd-8184-4a76-a2b0-233871b4a91f", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/4fd000fd-8184-4a76-a2b0-233871b4a91f/"},
119
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
120
+ "57c2f4dcd2fc2cf5b6b9f09b36193e5428e2b721dbc3ac79b326bcb07d8980e2", "epoch":
121
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160512.213034.40", "_id":
122
+ "a21512fe-b642-4c9c-bfb3-08283309dc44", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/a21512fe-b642-4c9c-bfb3-08283309dc44/"},
123
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
124
+ "5373e8dd2f712c63580d406277a75e29afcfa8f3ef21cdb587e9768440c8dbd7", "epoch":
125
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160512.142820.39", "_id":
126
+ "a939f53d-520c-4155-878e-1dade5028ddc", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/a939f53d-520c-4155-878e-1dade5028ddc/"},
127
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
128
+ "d0c45de8f7197290b0c3a49e73bdf2c07a531075832bdb267bab9d3f4225063c", "epoch":
129
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160510.184328.37", "_id":
130
+ "45be0e53-039c-4709-a41f-1bc2b8f14444", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/45be0e53-039c-4709-a41f-1bc2b8f14444/"},
131
+ {"repository_memberships": ["ent-cent7-dev"], "name": "cosmos-web", "checksum":
132
+ "97a8bf52ed37320aec4ddc064efc96f1d6ef85a2632a5fad358a4d6e35098eb4", "epoch":
133
+ "0", "version": "1.0.0_SNAPSHOT", "release": "b20160506.213118.36", "_id":
134
+ "e5e9e688-4839-4f06-a62d-551d35fc404b", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/e5e9e688-4839-4f06-a62d-551d35fc404b/"},
135
+ {"repository_memberships": [], "name": "cosmos-web", "checksum": "8adee7c93e4ab1cf51bae44e8aea2bf60a41af5b45a8dad5cc0af3d308c260dc",
136
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160506.211252.34",
137
+ "_id": "9a956a24-92d3-4433-9dca-2bb8a0661b4b", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/9a956a24-92d3-4433-9dca-2bb8a0661b4b/"},
138
+ {"repository_memberships": [], "name": "cosmos-web", "checksum": "875669ec02058a780a4e5158950eb073e0ff5a79f332a2ac9bf5f5febb13144d",
139
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160503.211005.29",
140
+ "_id": "c958fcb8-db2c-4599-a667-bfaa3e576043", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/c958fcb8-db2c-4599-a667-bfaa3e576043/"},
141
+ {"repository_memberships": [], "name": "cosmos-web", "checksum": "84cd4e24d3539d6d9420678ffa6761c84f4fd3d85cb73bffb1fe3ca6d66317e0",
142
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160421.145308.28",
143
+ "_id": "580b409c-4c7a-4820-84e3-04aa9f493e0f", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/580b409c-4c7a-4820-84e3-04aa9f493e0f/"},
144
+ {"repository_memberships": [], "name": "cosmos-web", "checksum": "ede362149a45cbf9713710f3631411bc7bee60fc75b4090f7e0a6f26a126604e",
145
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160414.173925.27",
146
+ "_id": "c96e836c-57f4-4c4a-be23-70375bed4119", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/c96e836c-57f4-4c4a-be23-70375bed4119/"},
147
+ {"repository_memberships": [], "name": "cosmos-web", "checksum": "76b818acdbab231510892144d1f27d2ab775b8ba10d3ec249afdbec3fe0fb367",
148
+ "epoch": "0", "version": "1.0.0_SNAPSHOT", "release": "b20160331.072130.26",
149
+ "_id": "104d49a9-fdda-40f3-9c85-9bac91294738", "children": {}, "_href": "/pulp/api/v2/content/units/rpm/104d49a9-fdda-40f3-9c85-9bac91294738/"}]'
150
+ http_version:
151
+ recorded_at: Wed, 29 Jun 2016 14:44:07 GMT
152
+ recorded_with: VCR 3.0.3
@@ -0,0 +1,35 @@
1
+ require "spec_helper"
2
+
3
+ vcr_options = { :record => :new_episodes }
4
+
5
+ describe Lita::Handlers::Pulp, lita_handler: true, :vcr => vcr_options do
6
+
7
+ before do
8
+ registry.config.handlers.pulp.url="https://pulp.co.epi.web"
9
+ registry.config.handlers.pulp.api_path="/pulp/api/v2/"
10
+ registry.config.handlers.pulp.username="admin"
11
+ registry.config.handlers.pulp.password="admin"
12
+ registry.config.handlers.pulp.verify_ssl=false
13
+ end
14
+
15
+ it do
16
+ is_expected.to route_command('pulp rpm repos').to(:rpm_repos)
17
+ is_expected.to route_command('pulp puppet repos').to(:puppet_repos)
18
+ end
19
+
20
+ describe '#rpm_repos' do
21
+ it 'list rpm repos' do
22
+ send_command("pulp rpm repos")
23
+ puts "*********************"
24
+ puts replies
25
+ end
26
+ end
27
+
28
+ describe '#puppet_repos' do
29
+ it 'list puppet repos' do
30
+ send_command("pulp puppet repos")
31
+ puts "*********************"
32
+ puts replies
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,79 @@
1
+ require "spec_helper"
2
+
3
+ vcr_options = { :record => :new_episodes }
4
+
5
+ describe Lita::Handlers::Pulp, lita_handler: true , :vcr => vcr_options do
6
+
7
+ before do
8
+ registry.config.handlers.pulp.url="https://pulp.co.epi.web"
9
+ registry.config.handlers.pulp.api_path="/pulp/api/v2/"
10
+ registry.config.handlers.pulp.username="admin"
11
+ registry.config.handlers.pulp.password="admin"
12
+ registry.config.handlers.pulp.verify_ssl=false
13
+ end
14
+
15
+ it do
16
+ is_expected.to route_command('pulp rpm search cosmos').to(:rpm_search)
17
+ is_expected.to route_command('pulp rpm search cosmos in dev').to(:rpm_search)
18
+ is_expected.to route_command('pulp puppet search cosmos').to(:puppet_search)
19
+ is_expected.to route_command('pulp puppet search cosmos in dev').to(:puppet_search)
20
+ is_expected.to route_command('pulp puppet copy -s forge_dev --to forge_qa --author entertainment --name cicd_test --version 0.1.33-pre100079-rev159b6f9 -d -p').to(:copy_puppet)
21
+ is_expected.to route_command('pulp rpm copy -s ent-cent7-dev --to ent-cent7-qa --name cosmos-web --version 1.0.0_SNAPSHOT --release b20160627.211338.63 --arch noarch').to(:copy_rpm)
22
+ end
23
+
24
+ describe '#rpm_search' do
25
+ it 'search rpm without repo' do
26
+ send_command("pulp rpm search cosmos")
27
+ puts "*********************"
28
+ #puts replies
29
+ end
30
+ it 'search rpm with repo' do
31
+ send_command("pulp rpm search cosmos in ent-cent7-qa")
32
+ puts "*********************"
33
+ #puts replies
34
+ end
35
+ end
36
+
37
+ describe '#puppet_search' do
38
+ it 'search puppet without repo' do
39
+ send_command("pulp puppet search cicd_test")
40
+ puts "*********************"
41
+ #puts replies
42
+ end
43
+ it 'search puppet with repo' do
44
+ send_command("pulp puppet search cicd_test in forge_dev")
45
+ puts "*********************"
46
+ #puts replies
47
+ end
48
+
49
+ it 'search puppet without author name' do
50
+ send_command("pulp puppet search entertainment/cicd_test")
51
+ puts "*********************"
52
+ #puts replies
53
+ end
54
+ end
55
+
56
+ describe '#copy_puppet_between_repo' do
57
+ it 'copy puppet module should fail with missing errors' do
58
+ send_command("pulp puppet copy -s forge_dev --to forge_qa --author entertainment --name cicd_test")
59
+ end
60
+ it 'copy puppet module' do
61
+ send_command("pulp puppet copy -s forge_dev --to forge_qa --author entertainment --name cicd_test --version 0.1.33-pre100079-rev159b6f9")
62
+ end
63
+ it 'copy puppet module delete new and publish' do
64
+ send_command("pulp puppet copy -s forge_dev --to forge_qa --author entertainment --name cicd_test --version 0.1.33-pre100079-rev159b6f9 -d -p")
65
+ end
66
+ end
67
+
68
+ describe '#copy_rpm_between_repo' do
69
+ it 'copy rpm package should fail with missing errors' do
70
+ send_command("pulp rpm copy -s ent-cent7-dev --to ent-cent7-qa --name cosmos-web --version 1.0.0_SNAPSHOT --release b20160627.211338.63")
71
+ end
72
+ it 'copy rpm package' do
73
+ send_command("pulp rpm copy -s ent-cent7-dev --to ent-cent7-qa --name cosmos-web --version 1.0.0_SNAPSHOT --release b20160627.211338.63 --arch noarch")
74
+ end
75
+ it 'copy rpm package delete new and publish' do
76
+ send_command("pulp rpm copy -s ent-cent7-dev --to ent-cent7-qa --name cosmos-web --version 1.0.0_SNAPSHOT --release b20160627.211338.63 --arch noarch -d -p")
77
+ end
78
+ end
79
+ end
@@ -0,0 +1,28 @@
1
+ require 'lita-keyword-arguments'
2
+ require "lita-pulp"
3
+ require "lita/rspec"
4
+
5
+ # A compatibility mode is provided for older plugins upgrading from Lita 3. Since this plugin
6
+ # was generated with Lita 4, the compatibility mode should be left disabled.
7
+ Lita.version_3_compatibility_mode = false
8
+
9
+ require 'vcr'
10
+
11
+
12
+ VCR.configure do |c|
13
+ c.cassette_library_dir = 'spec/fixtures/cassettes'
14
+ c.hook_into :webmock
15
+ c.configure_rspec_metadata!
16
+ end
17
+
18
+
19
+ RSpec.configure do |config|
20
+ config.before do
21
+ registry.register_handler(Lita::Handlers::Pulp)
22
+ registry.register_hook(:trigger_route, Lita::Extensions::KeywordArguments)
23
+ end
24
+ end
25
+
26
+ # def grab_request(result)
27
+ # allow(Runcible::Instance).to receive(:new) { result }
28
+ # end