foreman_acd 0.6.0 → 0.9.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (197) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +5 -5
  3. data/app/controllers/foreman_acd/ansible_playbooks_controller.rb +90 -0
  4. data/app/controllers/foreman_acd/app_definitions_controller.rb +104 -7
  5. data/app/controllers/foreman_acd/app_instances_controller.rb +34 -32
  6. data/app/controllers/foreman_acd/concerns/ansible_playbook_parameters.rb +1 -1
  7. data/app/controllers/foreman_acd/concerns/app_instance_mixins.rb +36 -0
  8. data/app/controllers/foreman_acd/remote_execution_controller.rb +37 -21
  9. data/app/controllers/ui_acd_controller.rb +42 -3
  10. data/app/lib/actions/foreman_acd/deploy_all_hosts.rb +12 -7
  11. data/app/lib/actions/foreman_acd/run_configurator.rb +11 -7
  12. data/app/models/concerns/foreman_acd/host_managed_extensions.rb +41 -28
  13. data/app/models/foreman_acd/acd_provider.rb +7 -1
  14. data/app/models/foreman_acd/ansible_playbook.rb +2 -1
  15. data/app/models/foreman_acd/app_instance.rb +48 -3
  16. data/app/models/foreman_acd/foreman_host.rb +8 -0
  17. data/app/services/foreman_acd/acd_proxy_proxy_selector.rb +17 -0
  18. data/app/services/foreman_acd/app_configurator.rb +59 -15
  19. data/app/services/foreman_acd/app_deployer.rb +27 -4
  20. data/app/services/foreman_acd/inventory_creator.rb +25 -1
  21. data/app/views/foreman_acd/ansible_playbooks/_form.html.erb +41 -7
  22. data/app/views/foreman_acd/app_definitions/_form.html.erb +5 -1
  23. data/app/views/foreman_acd/app_definitions/import.html.erb +20 -1
  24. data/app/views/foreman_acd/app_definitions/index.html.erb +3 -6
  25. data/app/views/foreman_acd/app_instances/_form.html.erb +5 -1
  26. data/app/views/foreman_acd/app_instances/index.html.erb +18 -12
  27. data/app/views/foreman_acd/app_instances/report.html.erb +8 -3
  28. data/app/views/templates/job/run_acd_ansible_playbook.erb +1 -1
  29. data/app/views/ui_acd/host_report.json.rabl +4 -0
  30. data/app/views/ui_acd/report_data.json.rabl +10 -0
  31. data/app/views/ui_acd/validate_hostname.json.rabl +6 -0
  32. data/config/routes.rb +6 -0
  33. data/db/migrate/20210316151145_add_git_commit_to_ansible_playbooks.rb +8 -0
  34. data/db/migrate/20210503122809_add_git_url_to_ansible_playbooks.rb +8 -0
  35. data/db/migrate/20210818125913_add_is_existing_host_to_foreman_host.rb +8 -0
  36. data/db/migrate/20210902110645_add_initial_configure_task.rb +8 -0
  37. data/db/seeds.d/75-job_templates.rb +1 -1
  38. data/lib/foreman_acd/engine.rb +26 -4
  39. data/lib/foreman_acd/plugin.rb +9 -18
  40. data/lib/foreman_acd/version.rb +1 -1
  41. data/lib/foreman_acd.rb +30 -0
  42. data/lib/tasks/foreman_acd_tasks.rake +0 -12
  43. data/package.json +8 -22
  44. data/test/controllers/ansible_playbooks_controller_test.rb +1 -1
  45. data/test/controllers/app_instances_controller_test.rb +8 -3
  46. data/test/controllers/ui_acd_controller_test.rb +25 -6
  47. data/test/factories/foreman_acd_factories.rb +18 -4
  48. data/test/models/acd_provider_test.rb +37 -0
  49. data/test/models/ansible_playbook_test.rb +11 -0
  50. data/test/models/app_definition_test.rb +1 -1
  51. data/test/models/app_instance_test.rb +2 -0
  52. data/test/models/concerns/host_extensions_test.rb +26 -0
  53. data/test/models/foreman_host_test.rb +12 -0
  54. data/webpack/__mocks__/foremanReact/API.js +2 -0
  55. data/webpack/__mocks__/foremanReact/common/I18n.js +3 -0
  56. data/webpack/__mocks__/foremanReact/common/helpers.js +2 -0
  57. data/webpack/__mocks__/foremanReact/components/ForemanModal/ForemanModalActions.js +2 -0
  58. data/webpack/__mocks__/foremanReact/components/ForemanModal.js +7 -0
  59. data/webpack/__mocks__/foremanReact/components/common/forms/CommonForm.js +2 -0
  60. data/webpack/__mocks__/foremanReact/components/common/forms/TextInput.js +2 -0
  61. data/webpack/__mocks__/foremanReact/components/hosts/powerStatus.js +1 -0
  62. data/webpack/__snapshots__/helper.test.js.snap +14 -0
  63. data/webpack/components/ApplicationDefinition/ApplicationDefinition.js +35 -11
  64. data/webpack/components/ApplicationDefinition/ApplicationDefinitionActions.js +12 -0
  65. data/webpack/components/ApplicationDefinition/ApplicationDefinitionConstants.js +1 -0
  66. data/webpack/components/ApplicationDefinition/ApplicationDefinitionReducer.js +30 -9
  67. data/webpack/components/ApplicationDefinition/ApplicationDefinitionSelectors.js +4 -0
  68. data/webpack/components/ApplicationDefinition/__fixtures__/applicationDefinitionConfData_1.fixtures.js +288 -0
  69. data/webpack/components/ApplicationDefinition/__fixtures__/applicationDefinitionReducer.fixtures.js +79 -0
  70. data/webpack/components/ApplicationDefinition/__tests__/ApplicationDefinition.test.js +26 -0
  71. data/webpack/components/ApplicationDefinition/__tests__/ApplicationDefinitionReducer.test.js +119 -0
  72. data/webpack/components/ApplicationDefinition/__tests__/ApplicationDefinitionSelectors.test.js +53 -0
  73. data/webpack/components/ApplicationDefinition/__tests__/__snapshots__/ApplicationDefinition.test.js.snap +226 -0
  74. data/webpack/components/ApplicationDefinition/__tests__/__snapshots__/ApplicationDefinitionReducer.test.js.snap +3033 -0
  75. data/webpack/components/ApplicationDefinition/__tests__/__snapshots__/ApplicationDefinitionSelectors.test.js.snap +307 -0
  76. data/webpack/components/ApplicationDefinition/components/AnsiblePlaybookSelector.js +2 -1
  77. data/webpack/components/ApplicationDefinition/components/__tests__/AnsiblePlaybookSelector.test.js +41 -0
  78. data/webpack/components/ApplicationDefinition/components/__tests__/__snapshots__/AnsiblePlaybookSelector.test.js.snap +121 -0
  79. data/webpack/components/ApplicationDefinition/index.js +8 -0
  80. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImport.js +214 -0
  81. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImport.scss +1 -0
  82. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportActions.js +161 -0
  83. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportConstants.js +6 -0
  84. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportReducer.js +79 -0
  85. data/webpack/components/ApplicationDefinitionImport/ApplicationDefinitionImportSelectors.js +8 -0
  86. data/webpack/components/ApplicationDefinitionImport/__fixtures__/applicationDefinitionImportConfData_1.fixtures.js +129 -0
  87. data/webpack/components/ApplicationDefinitionImport/__fixtures__/applicationDefinitionImportReducer.fixtures.js +29 -0
  88. data/webpack/components/ApplicationDefinitionImport/__tests__/ApplicationDefinitionImport.test.js +20 -0
  89. data/webpack/components/ApplicationDefinitionImport/__tests__/ApplicationDefinitionImportReducer.test.js +43 -0
  90. data/webpack/components/ApplicationDefinitionImport/__tests__/ApplicationDefinitionImportSelectors.test.js +29 -0
  91. data/webpack/components/ApplicationDefinitionImport/__tests__/__snapshots__/ApplicationDefinitionImport.test.js.snap +62 -0
  92. data/webpack/components/ApplicationDefinitionImport/__tests__/__snapshots__/ApplicationDefinitionImportReducer.test.js.snap +362 -0
  93. data/webpack/components/ApplicationDefinitionImport/__tests__/__snapshots__/ApplicationDefinitionImportSelectors.test.js.snap +130 -0
  94. data/webpack/components/ApplicationDefinitionImport/index.js +32 -0
  95. data/webpack/components/ApplicationInstance/ApplicationInstance.js +105 -31
  96. data/webpack/components/ApplicationInstance/ApplicationInstanceActions.js +118 -6
  97. data/webpack/components/ApplicationInstance/ApplicationInstanceConstants.js +4 -0
  98. data/webpack/components/ApplicationInstance/ApplicationInstanceHelper.js +15 -0
  99. data/webpack/components/ApplicationInstance/ApplicationInstanceReducer.js +71 -30
  100. data/webpack/components/ApplicationInstance/ApplicationInstanceSelectors.js +4 -0
  101. data/webpack/components/ApplicationInstance/__fixtures__/applicationInstanceConfData_1.fixtures.js +263 -0
  102. data/webpack/components/ApplicationInstance/__fixtures__/applicationInstanceReducer.fixtures.js +80 -0
  103. data/webpack/components/ApplicationInstance/__tests__/ApplicationInstance.test.js +24 -0
  104. data/webpack/components/ApplicationInstance/__tests__/ApplicationInstanceReducer.test.js +131 -0
  105. data/webpack/components/ApplicationInstance/__tests__/ApplicationInstanceSelectors.test.js +56 -0
  106. data/webpack/components/ApplicationInstance/__tests__/__snapshots__/ApplicationInstance.test.js.snap +300 -0
  107. data/webpack/components/ApplicationInstance/__tests__/__snapshots__/ApplicationInstanceReducer.test.js.snap +2990 -0
  108. data/webpack/components/ApplicationInstance/__tests__/__snapshots__/ApplicationInstanceSelectors.test.js.snap +284 -0
  109. data/webpack/components/ApplicationInstance/components/AppDefinitionSelector.js +1 -0
  110. data/webpack/components/ApplicationInstance/components/ServiceCounter.js +1 -1
  111. data/webpack/components/ApplicationInstance/helper.js +0 -0
  112. data/webpack/components/ApplicationInstance/index.js +8 -0
  113. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReport.js +81 -6
  114. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportActions.js +35 -1
  115. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportConstants.js +3 -0
  116. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportReducer.js +19 -0
  117. data/webpack/components/ApplicationInstanceReport/ApplicationInstanceReportSelectors.js +4 -0
  118. data/webpack/components/ApplicationInstanceReport/__fixtures__/applicationInstanceReportData_1.fixtures.js +349 -0
  119. data/webpack/components/ApplicationInstanceReport/__fixtures__/applicationInstanceReportReducer.fixtures.js +20 -0
  120. data/webpack/components/ApplicationInstanceReport/__tests__/ApplicationInstanceReport.test.js +47 -0
  121. data/webpack/components/ApplicationInstanceReport/__tests__/ApplicationInstanceReportReducer.test.js +41 -0
  122. data/webpack/components/ApplicationInstanceReport/__tests__/ApplicationInstanceReportSelectors.test.js +26 -0
  123. data/webpack/components/ApplicationInstanceReport/__tests__/__snapshots__/ApplicationInstanceReport.test.js.snap +7 -0
  124. data/webpack/components/ApplicationInstanceReport/__tests__/__snapshots__/ApplicationInstanceReportReducer.test.js.snap +718 -0
  125. data/webpack/components/ApplicationInstanceReport/__tests__/__snapshots__/ApplicationInstanceReportSelectors.test.js.snap +347 -0
  126. data/webpack/components/ApplicationInstanceReport/components/__tests__/ReportViewer.test.js +24 -0
  127. data/webpack/components/ApplicationInstanceReport/components/__tests__/__snapshots__/ReportViewer.test.js.snap +24 -0
  128. data/webpack/components/ApplicationInstanceReport/index.js +8 -1
  129. data/webpack/components/ExistingHostSelection/ExistingHostSelection.js +104 -0
  130. data/webpack/components/ExistingHostSelection/ExistingHostSelection.scss +15 -0
  131. data/webpack/components/ExistingHostSelection/ExistingHostSelectionActions.js +71 -0
  132. data/webpack/components/ExistingHostSelection/ExistingHostSelectionConstants.js +4 -0
  133. data/webpack/components/ExistingHostSelection/ExistingHostSelectionHelper.js +0 -0
  134. data/webpack/components/ExistingHostSelection/ExistingHostSelectionReducer.js +90 -0
  135. data/webpack/components/ExistingHostSelection/ExistingHostSelectionSelectors.js +8 -0
  136. data/webpack/components/ExistingHostSelection/__fixtures__/existingHostSelectionConfData_1.fixtures.js +191 -0
  137. data/webpack/components/ExistingHostSelection/__fixtures__/existingHostSelectionReducer.fixtures.js +203 -0
  138. data/webpack/components/ExistingHostSelection/__tests__/ExistingHostSelection.test.js +19 -0
  139. data/webpack/components/ExistingHostSelection/__tests__/ExistingHostSelectionReducer.test.js +59 -0
  140. data/webpack/components/ExistingHostSelection/__tests__/ExistingHostSelectionSelectors.test.js +36 -0
  141. data/webpack/components/ExistingHostSelection/__tests__/__snapshots__/ExistingHostSelection.test.js.snap +35 -0
  142. data/webpack/components/ExistingHostSelection/__tests__/__snapshots__/ExistingHostSelectionReducer.test.js.snap +614 -0
  143. data/webpack/components/ExistingHostSelection/__tests__/__snapshots__/ExistingHostSelectionSelectors.test.js.snap +27 -0
  144. data/webpack/components/ExistingHostSelection/components/ServiceSelector.js +48 -0
  145. data/webpack/components/ExistingHostSelection/components/__tests__/ServiceSelector.test.js +35 -0
  146. data/webpack/components/ExistingHostSelection/components/__tests__/__snapshots__/ServiceSelector.test.js.snap +77 -0
  147. data/webpack/components/ExistingHostSelection/index.js +26 -0
  148. data/webpack/components/ParameterSelection/ParameterSelection.js +103 -1
  149. data/webpack/components/ParameterSelection/ParameterSelection.scss +7 -0
  150. data/webpack/components/ParameterSelection/ParameterSelectionActions.js +46 -4
  151. data/webpack/components/ParameterSelection/ParameterSelectionConstants.js +2 -0
  152. data/webpack/components/ParameterSelection/ParameterSelectionHelper.js +5 -1
  153. data/webpack/components/ParameterSelection/ParameterSelectionReducer.js +51 -29
  154. data/webpack/components/ParameterSelection/ParameterSelectionSelectors.js +2 -0
  155. data/webpack/components/ParameterSelection/__fixtures__/parameterSelectionData_1.fixtures.js +124 -84
  156. data/webpack/components/ParameterSelection/__fixtures__/parameterSelectionReducer.fixtures.js +10 -4
  157. data/webpack/components/ParameterSelection/__tests__/ParameterSelection.test.js +36 -46
  158. data/webpack/components/ParameterSelection/__tests__/ParameterSelectionReducer.test.js +33 -25
  159. data/webpack/components/ParameterSelection/__tests__/ParameterSelectionSelectors.test.js +12 -6
  160. data/webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelection.test.js.snap +84 -112
  161. data/webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelectionReducer.test.js.snap +1589 -878
  162. data/webpack/components/ParameterSelection/__tests__/__snapshots__/ParameterSelectionSelectors.test.js.snap +130 -79
  163. data/webpack/components/ParameterSelection/index.js +4 -1
  164. data/webpack/components/SyncGitRepo/SyncGitRepo.js +202 -0
  165. data/webpack/components/SyncGitRepo/SyncGitRepo.scss +1 -0
  166. data/webpack/components/SyncGitRepo/SyncGitRepoActions.js +123 -0
  167. data/webpack/components/SyncGitRepo/SyncGitRepoConstants.js +8 -0
  168. data/webpack/components/SyncGitRepo/SyncGitRepoReducer.js +80 -0
  169. data/webpack/components/SyncGitRepo/SyncGitRepoSelectors.js +6 -0
  170. data/webpack/components/SyncGitRepo/__fixtures__/syncGitRepoConfData_1.fixtures.js +7 -0
  171. data/webpack/components/SyncGitRepo/__fixtures__/syncGitRepoReducer.fixtures.js +44 -0
  172. data/webpack/components/SyncGitRepo/__tests__/SyncGitRepo.test.js +27 -0
  173. data/webpack/components/SyncGitRepo/__tests__/SyncGitRepoReducer.test.js +95 -0
  174. data/webpack/components/SyncGitRepo/__tests__/SyncGitRepoSelectors.test.js +32 -0
  175. data/webpack/components/SyncGitRepo/__tests__/__snapshots__/SyncGitRepo.test.js.snap +31 -0
  176. data/webpack/components/SyncGitRepo/__tests__/__snapshots__/SyncGitRepoReducer.test.js.snap +137 -0
  177. data/webpack/components/SyncGitRepo/__tests__/__snapshots__/SyncGitRepoSelectors.test.js.snap +13 -0
  178. data/webpack/components/SyncGitRepo/components/FormTextInput.js +42 -0
  179. data/webpack/components/SyncGitRepo/components/ScmTypeSelector.js +47 -0
  180. data/webpack/components/SyncGitRepo/index.js +28 -0
  181. data/webpack/components/common/DeleteTableEntry.js +16 -2
  182. data/webpack/components/common/ExtTextInput.js +43 -0
  183. data/webpack/components/common/__tests__/EditTableEntry.test.js +53 -0
  184. data/webpack/components/common/__tests__/LockTableEntry.test.js +35 -0
  185. data/webpack/components/common/__tests__/__snapshots__/DeleteTableEntry.test.js.snap +40 -2
  186. data/webpack/components/common/__tests__/__snapshots__/EditTableEntry.test.js.snap +81 -0
  187. data/webpack/components/common/__tests__/__snapshots__/LockTableEntry.test.js.snap +60 -0
  188. data/webpack/helper.js +35 -1
  189. data/webpack/helper.test.js +56 -0
  190. data/webpack/index.js +7 -0
  191. data/webpack/js-yaml.js +3874 -0
  192. data/webpack/reducer.js +16 -1
  193. data/webpack/test_setup.js +0 -2
  194. metadata +136 -11
  195. data/webpack/components/common/EasyHeaderFormatter.js +0 -18
  196. data/webpack/components/common/__tests__/__snapshots__/AddParameter.test.js.snap +0 -35
  197. data/webpack/components/common/__tests__/__snapshots__/DeleteParameter.test.js.snap +0 -41
@@ -0,0 +1,2990 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`ApplicationInstanceReducer should activate edit host 1`] = `
4
+ Object {
5
+ "ansibleVarsAll": Array [
6
+ Object {
7
+ "id": 0,
8
+ "name": "repository",
9
+ "value": "https://github.com/bennojoy/mywebapp.git",
10
+ },
11
+ ],
12
+ "appDefinition": Object {
13
+ "ansible_vars_all": "[{\\"id\\":0,\\"name\\":\\"repository\\",\\"value\\":\\"https://github.com/bennojoy/mywebapp.git\\"}]",
14
+ "created_at": "2021-03-11 12:51:34 +0100",
15
+ "description": "",
16
+ "id": 1,
17
+ "location_ids": Array [
18
+ 2,
19
+ ],
20
+ "name": "LAMP",
21
+ "organization_ids": Array [
22
+ 1,
23
+ ],
24
+ "services": "[{\\"id\\":1,\\"name\\":\\"web\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"webservers\\",\\"minCount\\":\\"2\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[{\\"id\\":1,\\"locked\\":false,\\"name\\":\\"CP\\",\\"description\\":\\"\\",\\"type\\":\\"computeprofile\\",\\"value\\":\\"1\\"},{\\"id\\":2,\\"locked\\":true,\\"name\\":\\"LE\\",\\"description\\":\\"\\",\\"type\\":\\"lifecycleenv\\",\\"value\\":\\"1\\"}],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"dummy_var\\",\\"value\\":\\"0\\"}]},{\\"id\\":2,\\"name\\":\\"db\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"dbservers\\",\\"minCount\\":\\"1\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"mysqlservice\\",\\"value\\":\\"mysqld\\"},{\\"id\\":1,\\"name\\":\\"mysql_port\\",\\"value\\":\\"3306\\",\\"locked\\":true},{\\"id\\":2,\\"name\\":\\"dbuser\\",\\"value\\":\\"webapp\\"},{\\"id\\":3,\\"name\\":\\"dbname\\",\\"value\\":\\"ANSAP01\\"},{\\"id\\":4,\\"name\\":\\"upassword\\",\\"value\\":\\"Bond@007\\"},{\\"id\\":5,\\"name\\":\\"masterpassword\\",\\"value\\":\\"MySQL@007\\"}]}]",
25
+ "updated_at": "2021-03-13 00:06:12 +0100",
26
+ },
27
+ "columns": Array [
28
+ Object {
29
+ "cell": Object {
30
+ "formatters": Array [
31
+ null,
32
+ ],
33
+ },
34
+ "header": Object {
35
+ "formatters": Array [
36
+ null,
37
+ ],
38
+ "label": "Hostname",
39
+ "props": Object {
40
+ "index": 0,
41
+ "style": Object {
42
+ "width": "30%",
43
+ },
44
+ },
45
+ },
46
+ "property": "hostname",
47
+ },
48
+ Object {
49
+ "cell": Object {
50
+ "formatters": Array [
51
+ null,
52
+ ],
53
+ },
54
+ "header": Object {
55
+ "formatters": Array [
56
+ null,
57
+ ],
58
+ "label": "Description",
59
+ "props": Object {
60
+ "index": 1,
61
+ "style": Object {
62
+ "width": "30%",
63
+ },
64
+ },
65
+ },
66
+ "property": "description",
67
+ },
68
+ Object {
69
+ "cell": Object {
70
+ "formatters": Array [
71
+ null,
72
+ ],
73
+ },
74
+ "header": Object {
75
+ "formatters": Array [
76
+ null,
77
+ ],
78
+ "label": "Service",
79
+ "props": Object {
80
+ "index": 2,
81
+ "style": Object {
82
+ "width": "20%",
83
+ },
84
+ },
85
+ },
86
+ "property": "service",
87
+ },
88
+ Object {
89
+ "cell": Object {
90
+ "formatters": Array [
91
+ null,
92
+ ],
93
+ },
94
+ "header": Object {
95
+ "formatters": Array [
96
+ null,
97
+ ],
98
+ "label": "Actions",
99
+ "props": Object {
100
+ "index": 4,
101
+ "style": Object {
102
+ "width": "20%",
103
+ },
104
+ },
105
+ },
106
+ "property": "actions",
107
+ },
108
+ ],
109
+ "editMode": true,
110
+ "error": Object {
111
+ "errorMsg": "",
112
+ "status": "",
113
+ "statusText": "",
114
+ },
115
+ "hosts": Array [
116
+ Object {
117
+ "ansibleParameters": Array [
118
+ Object {
119
+ "id": 0,
120
+ "name": "mysqlservice",
121
+ "value": "mysqld",
122
+ },
123
+ Object {
124
+ "id": 1,
125
+ "name": "mysql_port",
126
+ "value": "3306",
127
+ },
128
+ Object {
129
+ "id": 2,
130
+ "name": "dbuser",
131
+ "value": "webapp",
132
+ },
133
+ Object {
134
+ "id": 3,
135
+ "name": "dbname",
136
+ "value": "ANSAP01",
137
+ },
138
+ Object {
139
+ "id": 4,
140
+ "name": "upassword",
141
+ "value": "Bond@007",
142
+ },
143
+ Object {
144
+ "id": 5,
145
+ "name": "masterpassword",
146
+ "value": "MySQL@007",
147
+ },
148
+ ],
149
+ "description": "",
150
+ "foremanParameters": Array [],
151
+ "hostname": "great-web-app-db-1",
152
+ "id": 4,
153
+ "service": "2",
154
+ },
155
+ Object {
156
+ "ansibleParameters": Array [
157
+ Object {
158
+ "id": 0,
159
+ "name": "dummy_var",
160
+ "value": "0",
161
+ },
162
+ ],
163
+ "description": "",
164
+ "foremanParameters": Array [],
165
+ "hostname": "great-web-app-web-1",
166
+ "id": 1,
167
+ "service": "1",
168
+ },
169
+ Object {
170
+ "ansibleParameters": Array [
171
+ Object {
172
+ "id": 0,
173
+ "name": "dummy_var",
174
+ "value": "0",
175
+ },
176
+ ],
177
+ "backup": Object {
178
+ "ansibleParameters": Array [
179
+ Object {
180
+ "id": 0,
181
+ "name": "dummy_var",
182
+ "value": "0",
183
+ },
184
+ ],
185
+ "description": "",
186
+ "foremanParameters": Array [],
187
+ "hostname": "great-web-app-web-2",
188
+ "id": 2,
189
+ "service": "1",
190
+ },
191
+ "description": "",
192
+ "foremanParameters": Array [],
193
+ "hostname": "great-web-app-web-2",
194
+ "id": 2,
195
+ "service": "1",
196
+ },
197
+ ],
198
+ "loading": false,
199
+ "name": false,
200
+ "services": Array [
201
+ Object {
202
+ "ansibleGroup": "webservers",
203
+ "ansibleParameters": Array [
204
+ Object {
205
+ "id": 0,
206
+ "name": "dummy_var",
207
+ "value": "0",
208
+ },
209
+ ],
210
+ "currentCount": 2,
211
+ "description": "",
212
+ "foremanParameters": Array [
213
+ Object {
214
+ "description": "",
215
+ "id": 1,
216
+ "locked": false,
217
+ "name": "CP",
218
+ "type": "computeprofile",
219
+ "value": "1",
220
+ },
221
+ Object {
222
+ "description": "",
223
+ "id": 2,
224
+ "locked": true,
225
+ "name": "LE",
226
+ "type": "lifecycleenv",
227
+ "value": "1",
228
+ },
229
+ ],
230
+ "hostgroup": "1",
231
+ "id": 1,
232
+ "maxCount": "",
233
+ "minCount": "2",
234
+ "name": "web",
235
+ },
236
+ Object {
237
+ "ansibleGroup": "dbservers",
238
+ "ansibleParameters": Array [
239
+ Object {
240
+ "id": 0,
241
+ "name": "mysqlservice",
242
+ "value": "mysqld",
243
+ },
244
+ Object {
245
+ "id": 1,
246
+ "locked": true,
247
+ "name": "mysql_port",
248
+ "value": "3306",
249
+ },
250
+ Object {
251
+ "id": 2,
252
+ "name": "dbuser",
253
+ "value": "webapp",
254
+ },
255
+ Object {
256
+ "id": 3,
257
+ "name": "dbname",
258
+ "value": "ANSAP01",
259
+ },
260
+ Object {
261
+ "id": 4,
262
+ "name": "upassword",
263
+ "value": "Bond@007",
264
+ },
265
+ Object {
266
+ "id": 5,
267
+ "name": "masterpassword",
268
+ "value": "MySQL@007",
269
+ },
270
+ ],
271
+ "currentCount": 1,
272
+ "description": "",
273
+ "foremanParameters": Array [],
274
+ "hostgroup": "1",
275
+ "id": 2,
276
+ "maxCount": "",
277
+ "minCount": "1",
278
+ "name": "db",
279
+ },
280
+ ],
281
+ }
282
+ `;
283
+
284
+ exports[`ApplicationInstanceReducer should add a host 1`] = `
285
+ Object {
286
+ "ansibleVarsAll": Array [
287
+ Object {
288
+ "id": 0,
289
+ "name": "repository",
290
+ "value": "https://github.com/bennojoy/mywebapp.git",
291
+ },
292
+ ],
293
+ "appDefinition": Object {
294
+ "ansible_vars_all": "[{\\"id\\":0,\\"name\\":\\"repository\\",\\"value\\":\\"https://github.com/bennojoy/mywebapp.git\\"}]",
295
+ "created_at": "2021-03-11 12:51:34 +0100",
296
+ "description": "",
297
+ "id": 1,
298
+ "location_ids": Array [
299
+ 2,
300
+ ],
301
+ "name": "LAMP",
302
+ "organization_ids": Array [
303
+ 1,
304
+ ],
305
+ "services": "[{\\"id\\":1,\\"name\\":\\"web\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"webservers\\",\\"minCount\\":\\"2\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[{\\"id\\":1,\\"locked\\":false,\\"name\\":\\"CP\\",\\"description\\":\\"\\",\\"type\\":\\"computeprofile\\",\\"value\\":\\"1\\"},{\\"id\\":2,\\"locked\\":true,\\"name\\":\\"LE\\",\\"description\\":\\"\\",\\"type\\":\\"lifecycleenv\\",\\"value\\":\\"1\\"}],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"dummy_var\\",\\"value\\":\\"0\\"}]},{\\"id\\":2,\\"name\\":\\"db\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"dbservers\\",\\"minCount\\":\\"1\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"mysqlservice\\",\\"value\\":\\"mysqld\\"},{\\"id\\":1,\\"name\\":\\"mysql_port\\",\\"value\\":\\"3306\\",\\"locked\\":true},{\\"id\\":2,\\"name\\":\\"dbuser\\",\\"value\\":\\"webapp\\"},{\\"id\\":3,\\"name\\":\\"dbname\\",\\"value\\":\\"ANSAP01\\"},{\\"id\\":4,\\"name\\":\\"upassword\\",\\"value\\":\\"Bond@007\\"},{\\"id\\":5,\\"name\\":\\"masterpassword\\",\\"value\\":\\"MySQL@007\\"}]}]",
306
+ "updated_at": "2021-03-13 00:06:12 +0100",
307
+ },
308
+ "columns": Array [
309
+ Object {
310
+ "cell": Object {
311
+ "formatters": Array [
312
+ null,
313
+ ],
314
+ },
315
+ "header": Object {
316
+ "formatters": Array [
317
+ null,
318
+ ],
319
+ "label": "Hostname",
320
+ "props": Object {
321
+ "index": 0,
322
+ "style": Object {
323
+ "width": "30%",
324
+ },
325
+ },
326
+ },
327
+ "property": "hostname",
328
+ },
329
+ Object {
330
+ "cell": Object {
331
+ "formatters": Array [
332
+ null,
333
+ ],
334
+ },
335
+ "header": Object {
336
+ "formatters": Array [
337
+ null,
338
+ ],
339
+ "label": "Description",
340
+ "props": Object {
341
+ "index": 1,
342
+ "style": Object {
343
+ "width": "30%",
344
+ },
345
+ },
346
+ },
347
+ "property": "description",
348
+ },
349
+ Object {
350
+ "cell": Object {
351
+ "formatters": Array [
352
+ null,
353
+ ],
354
+ },
355
+ "header": Object {
356
+ "formatters": Array [
357
+ null,
358
+ ],
359
+ "label": "Service",
360
+ "props": Object {
361
+ "index": 2,
362
+ "style": Object {
363
+ "width": "20%",
364
+ },
365
+ },
366
+ },
367
+ "property": "service",
368
+ },
369
+ Object {
370
+ "cell": Object {
371
+ "formatters": Array [
372
+ null,
373
+ ],
374
+ },
375
+ "header": Object {
376
+ "formatters": Array [
377
+ null,
378
+ ],
379
+ "label": "Actions",
380
+ "props": Object {
381
+ "index": 4,
382
+ "style": Object {
383
+ "width": "20%",
384
+ },
385
+ },
386
+ },
387
+ "property": "actions",
388
+ },
389
+ ],
390
+ "editMode": true,
391
+ "error": Object {
392
+ "errorMsg": "",
393
+ "status": "",
394
+ "statusText": "",
395
+ },
396
+ "hosts": Array [
397
+ Object {
398
+ "ansibleParameters": Array [
399
+ Object {
400
+ "id": 0,
401
+ "name": "mysqlservice",
402
+ "value": "mysqld",
403
+ },
404
+ Object {
405
+ "id": 1,
406
+ "name": "mysql_port",
407
+ "value": "3306",
408
+ },
409
+ Object {
410
+ "id": 2,
411
+ "name": "dbuser",
412
+ "value": "webapp",
413
+ },
414
+ Object {
415
+ "id": 3,
416
+ "name": "dbname",
417
+ "value": "ANSAP01",
418
+ },
419
+ Object {
420
+ "id": 4,
421
+ "name": "upassword",
422
+ "value": "Bond@007",
423
+ },
424
+ Object {
425
+ "id": 5,
426
+ "name": "masterpassword",
427
+ "value": "MySQL@007",
428
+ },
429
+ ],
430
+ "description": "",
431
+ "foremanParameters": Array [],
432
+ "hostname": "great-web-app-db-1",
433
+ "id": 4,
434
+ "service": "2",
435
+ },
436
+ Object {
437
+ "ansibleParameters": Array [
438
+ Object {
439
+ "id": 0,
440
+ "name": "dummy_var",
441
+ "value": "0",
442
+ },
443
+ ],
444
+ "description": "",
445
+ "foremanParameters": Array [],
446
+ "hostname": "great-web-app-web-1",
447
+ "id": 1,
448
+ "service": "1",
449
+ },
450
+ Object {
451
+ "ansibleParameters": Array [
452
+ Object {
453
+ "id": 0,
454
+ "name": "dummy_var",
455
+ "value": "0",
456
+ },
457
+ ],
458
+ "description": "",
459
+ "foremanParameters": Array [],
460
+ "hostname": "great-web-app-web-2",
461
+ "id": 2,
462
+ "service": "1",
463
+ },
464
+ Object {
465
+ "ansibleParameters": Array [],
466
+ "backup": Object {
467
+ "ansibleParameters": Array [],
468
+ "description": "",
469
+ "foremanParameters": Array [],
470
+ "hostname": "",
471
+ "id": 5,
472
+ "isExistingHost": false,
473
+ "newEntry": true,
474
+ "service": "",
475
+ },
476
+ "description": "",
477
+ "foremanParameters": Array [],
478
+ "hostname": "",
479
+ "id": 5,
480
+ "isExistingHost": false,
481
+ "newEntry": true,
482
+ "service": "",
483
+ },
484
+ ],
485
+ "loading": false,
486
+ "name": false,
487
+ "services": Array [
488
+ Object {
489
+ "ansibleGroup": "webservers",
490
+ "ansibleParameters": Array [
491
+ Object {
492
+ "id": 0,
493
+ "name": "dummy_var",
494
+ "value": "0",
495
+ },
496
+ ],
497
+ "currentCount": 2,
498
+ "description": "",
499
+ "foremanParameters": Array [
500
+ Object {
501
+ "description": "",
502
+ "id": 1,
503
+ "locked": false,
504
+ "name": "CP",
505
+ "type": "computeprofile",
506
+ "value": "1",
507
+ },
508
+ Object {
509
+ "description": "",
510
+ "id": 2,
511
+ "locked": true,
512
+ "name": "LE",
513
+ "type": "lifecycleenv",
514
+ "value": "1",
515
+ },
516
+ ],
517
+ "hostgroup": "1",
518
+ "id": 1,
519
+ "maxCount": "",
520
+ "minCount": "2",
521
+ "name": "web",
522
+ },
523
+ Object {
524
+ "ansibleGroup": "dbservers",
525
+ "ansibleParameters": Array [
526
+ Object {
527
+ "id": 0,
528
+ "name": "mysqlservice",
529
+ "value": "mysqld",
530
+ },
531
+ Object {
532
+ "id": 1,
533
+ "locked": true,
534
+ "name": "mysql_port",
535
+ "value": "3306",
536
+ },
537
+ Object {
538
+ "id": 2,
539
+ "name": "dbuser",
540
+ "value": "webapp",
541
+ },
542
+ Object {
543
+ "id": 3,
544
+ "name": "dbname",
545
+ "value": "ANSAP01",
546
+ },
547
+ Object {
548
+ "id": 4,
549
+ "name": "upassword",
550
+ "value": "Bond@007",
551
+ },
552
+ Object {
553
+ "id": 5,
554
+ "name": "masterpassword",
555
+ "value": "MySQL@007",
556
+ },
557
+ ],
558
+ "currentCount": 1,
559
+ "description": "",
560
+ "foremanParameters": Array [],
561
+ "hostgroup": "1",
562
+ "id": 2,
563
+ "maxCount": "",
564
+ "minCount": "1",
565
+ "name": "db",
566
+ },
567
+ ],
568
+ }
569
+ `;
570
+
571
+ exports[`ApplicationInstanceReducer should cancel edit host 1`] = `
572
+ Object {
573
+ "ansibleVarsAll": Array [
574
+ Object {
575
+ "id": 0,
576
+ "name": "repository",
577
+ "value": "https://github.com/bennojoy/mywebapp.git",
578
+ },
579
+ ],
580
+ "appDefinition": Object {
581
+ "ansible_vars_all": "[{\\"id\\":0,\\"name\\":\\"repository\\",\\"value\\":\\"https://github.com/bennojoy/mywebapp.git\\"}]",
582
+ "created_at": "2021-03-11 12:51:34 +0100",
583
+ "description": "",
584
+ "id": 1,
585
+ "location_ids": Array [
586
+ 2,
587
+ ],
588
+ "name": "LAMP",
589
+ "organization_ids": Array [
590
+ 1,
591
+ ],
592
+ "services": "[{\\"id\\":1,\\"name\\":\\"web\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"webservers\\",\\"minCount\\":\\"2\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[{\\"id\\":1,\\"locked\\":false,\\"name\\":\\"CP\\",\\"description\\":\\"\\",\\"type\\":\\"computeprofile\\",\\"value\\":\\"1\\"},{\\"id\\":2,\\"locked\\":true,\\"name\\":\\"LE\\",\\"description\\":\\"\\",\\"type\\":\\"lifecycleenv\\",\\"value\\":\\"1\\"}],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"dummy_var\\",\\"value\\":\\"0\\"}]},{\\"id\\":2,\\"name\\":\\"db\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"dbservers\\",\\"minCount\\":\\"1\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"mysqlservice\\",\\"value\\":\\"mysqld\\"},{\\"id\\":1,\\"name\\":\\"mysql_port\\",\\"value\\":\\"3306\\",\\"locked\\":true},{\\"id\\":2,\\"name\\":\\"dbuser\\",\\"value\\":\\"webapp\\"},{\\"id\\":3,\\"name\\":\\"dbname\\",\\"value\\":\\"ANSAP01\\"},{\\"id\\":4,\\"name\\":\\"upassword\\",\\"value\\":\\"Bond@007\\"},{\\"id\\":5,\\"name\\":\\"masterpassword\\",\\"value\\":\\"MySQL@007\\"}]}]",
593
+ "updated_at": "2021-03-13 00:06:12 +0100",
594
+ },
595
+ "columns": Array [
596
+ Object {
597
+ "cell": Object {
598
+ "formatters": Array [
599
+ null,
600
+ ],
601
+ },
602
+ "header": Object {
603
+ "formatters": Array [
604
+ null,
605
+ ],
606
+ "label": "Hostname",
607
+ "props": Object {
608
+ "index": 0,
609
+ "style": Object {
610
+ "width": "30%",
611
+ },
612
+ },
613
+ },
614
+ "property": "hostname",
615
+ },
616
+ Object {
617
+ "cell": Object {
618
+ "formatters": Array [
619
+ null,
620
+ ],
621
+ },
622
+ "header": Object {
623
+ "formatters": Array [
624
+ null,
625
+ ],
626
+ "label": "Description",
627
+ "props": Object {
628
+ "index": 1,
629
+ "style": Object {
630
+ "width": "30%",
631
+ },
632
+ },
633
+ },
634
+ "property": "description",
635
+ },
636
+ Object {
637
+ "cell": Object {
638
+ "formatters": Array [
639
+ null,
640
+ ],
641
+ },
642
+ "header": Object {
643
+ "formatters": Array [
644
+ null,
645
+ ],
646
+ "label": "Service",
647
+ "props": Object {
648
+ "index": 2,
649
+ "style": Object {
650
+ "width": "20%",
651
+ },
652
+ },
653
+ },
654
+ "property": "service",
655
+ },
656
+ Object {
657
+ "cell": Object {
658
+ "formatters": Array [
659
+ null,
660
+ ],
661
+ },
662
+ "header": Object {
663
+ "formatters": Array [
664
+ null,
665
+ ],
666
+ "label": "Actions",
667
+ "props": Object {
668
+ "index": 4,
669
+ "style": Object {
670
+ "width": "20%",
671
+ },
672
+ },
673
+ },
674
+ "property": "actions",
675
+ },
676
+ ],
677
+ "editMode": false,
678
+ "error": Object {
679
+ "errorMsg": "",
680
+ "status": "",
681
+ "statusText": "",
682
+ },
683
+ "hosts": Array [
684
+ Object {
685
+ "ansibleParameters": Array [
686
+ Object {
687
+ "id": 0,
688
+ "name": "mysqlservice",
689
+ "value": "mysqld",
690
+ },
691
+ Object {
692
+ "id": 1,
693
+ "name": "mysql_port",
694
+ "value": "3306",
695
+ },
696
+ Object {
697
+ "id": 2,
698
+ "name": "dbuser",
699
+ "value": "webapp",
700
+ },
701
+ Object {
702
+ "id": 3,
703
+ "name": "dbname",
704
+ "value": "ANSAP01",
705
+ },
706
+ Object {
707
+ "id": 4,
708
+ "name": "upassword",
709
+ "value": "Bond@007",
710
+ },
711
+ Object {
712
+ "id": 5,
713
+ "name": "masterpassword",
714
+ "value": "MySQL@007",
715
+ },
716
+ ],
717
+ "description": "",
718
+ "foremanParameters": Array [],
719
+ "hostname": "great-web-app-db-1",
720
+ "id": 4,
721
+ "service": "2",
722
+ },
723
+ Object {
724
+ "ansibleParameters": Array [
725
+ Object {
726
+ "id": 0,
727
+ "name": "dummy_var",
728
+ "value": "0",
729
+ },
730
+ ],
731
+ "description": "",
732
+ "foremanParameters": Array [],
733
+ "hostname": "great-web-app-web-1",
734
+ "id": 1,
735
+ "service": "1",
736
+ },
737
+ Object {
738
+ "ansibleParameters": Array [
739
+ Object {
740
+ "id": 0,
741
+ "name": "dummy_var",
742
+ "value": "0",
743
+ },
744
+ ],
745
+ "description": "",
746
+ "foremanParameters": Array [],
747
+ "hostname": "great-web-app-web-2",
748
+ "id": 2,
749
+ "service": "1",
750
+ },
751
+ ],
752
+ "loading": false,
753
+ "name": false,
754
+ "services": Array [
755
+ Object {
756
+ "ansibleGroup": "webservers",
757
+ "ansibleParameters": Array [
758
+ Object {
759
+ "id": 0,
760
+ "name": "dummy_var",
761
+ "value": "0",
762
+ },
763
+ ],
764
+ "currentCount": 2,
765
+ "description": "",
766
+ "foremanParameters": Array [
767
+ Object {
768
+ "description": "",
769
+ "id": 1,
770
+ "locked": false,
771
+ "name": "CP",
772
+ "type": "computeprofile",
773
+ "value": "1",
774
+ },
775
+ Object {
776
+ "description": "",
777
+ "id": 2,
778
+ "locked": true,
779
+ "name": "LE",
780
+ "type": "lifecycleenv",
781
+ "value": "1",
782
+ },
783
+ ],
784
+ "hostgroup": "1",
785
+ "id": 1,
786
+ "maxCount": "",
787
+ "minCount": "2",
788
+ "name": "web",
789
+ },
790
+ Object {
791
+ "ansibleGroup": "dbservers",
792
+ "ansibleParameters": Array [
793
+ Object {
794
+ "id": 0,
795
+ "name": "mysqlservice",
796
+ "value": "mysqld",
797
+ },
798
+ Object {
799
+ "id": 1,
800
+ "locked": true,
801
+ "name": "mysql_port",
802
+ "value": "3306",
803
+ },
804
+ Object {
805
+ "id": 2,
806
+ "name": "dbuser",
807
+ "value": "webapp",
808
+ },
809
+ Object {
810
+ "id": 3,
811
+ "name": "dbname",
812
+ "value": "ANSAP01",
813
+ },
814
+ Object {
815
+ "id": 4,
816
+ "name": "upassword",
817
+ "value": "Bond@007",
818
+ },
819
+ Object {
820
+ "id": 5,
821
+ "name": "masterpassword",
822
+ "value": "MySQL@007",
823
+ },
824
+ ],
825
+ "currentCount": 1,
826
+ "description": "",
827
+ "foremanParameters": Array [],
828
+ "hostgroup": "1",
829
+ "id": 2,
830
+ "maxCount": "",
831
+ "minCount": "1",
832
+ "name": "db",
833
+ },
834
+ ],
835
+ }
836
+ `;
837
+
838
+ exports[`ApplicationInstanceReducer should change edit host 1`] = `
839
+ Object {
840
+ "ansibleVarsAll": Array [
841
+ Object {
842
+ "id": 0,
843
+ "name": "repository",
844
+ "value": "https://github.com/bennojoy/mywebapp.git",
845
+ },
846
+ ],
847
+ "appDefinition": Object {
848
+ "ansible_vars_all": "[{\\"id\\":0,\\"name\\":\\"repository\\",\\"value\\":\\"https://github.com/bennojoy/mywebapp.git\\"}]",
849
+ "created_at": "2021-03-11 12:51:34 +0100",
850
+ "description": "",
851
+ "id": 1,
852
+ "location_ids": Array [
853
+ 2,
854
+ ],
855
+ "name": "LAMP",
856
+ "organization_ids": Array [
857
+ 1,
858
+ ],
859
+ "services": "[{\\"id\\":1,\\"name\\":\\"web\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"webservers\\",\\"minCount\\":\\"2\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[{\\"id\\":1,\\"locked\\":false,\\"name\\":\\"CP\\",\\"description\\":\\"\\",\\"type\\":\\"computeprofile\\",\\"value\\":\\"1\\"},{\\"id\\":2,\\"locked\\":true,\\"name\\":\\"LE\\",\\"description\\":\\"\\",\\"type\\":\\"lifecycleenv\\",\\"value\\":\\"1\\"}],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"dummy_var\\",\\"value\\":\\"0\\"}]},{\\"id\\":2,\\"name\\":\\"db\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"dbservers\\",\\"minCount\\":\\"1\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"mysqlservice\\",\\"value\\":\\"mysqld\\"},{\\"id\\":1,\\"name\\":\\"mysql_port\\",\\"value\\":\\"3306\\",\\"locked\\":true},{\\"id\\":2,\\"name\\":\\"dbuser\\",\\"value\\":\\"webapp\\"},{\\"id\\":3,\\"name\\":\\"dbname\\",\\"value\\":\\"ANSAP01\\"},{\\"id\\":4,\\"name\\":\\"upassword\\",\\"value\\":\\"Bond@007\\"},{\\"id\\":5,\\"name\\":\\"masterpassword\\",\\"value\\":\\"MySQL@007\\"}]}]",
860
+ "updated_at": "2021-03-13 00:06:12 +0100",
861
+ },
862
+ "columns": Array [
863
+ Object {
864
+ "cell": Object {
865
+ "formatters": Array [
866
+ null,
867
+ ],
868
+ },
869
+ "header": Object {
870
+ "formatters": Array [
871
+ null,
872
+ ],
873
+ "label": "Hostname",
874
+ "props": Object {
875
+ "index": 0,
876
+ "style": Object {
877
+ "width": "30%",
878
+ },
879
+ },
880
+ },
881
+ "property": "hostname",
882
+ },
883
+ Object {
884
+ "cell": Object {
885
+ "formatters": Array [
886
+ null,
887
+ ],
888
+ },
889
+ "header": Object {
890
+ "formatters": Array [
891
+ null,
892
+ ],
893
+ "label": "Description",
894
+ "props": Object {
895
+ "index": 1,
896
+ "style": Object {
897
+ "width": "30%",
898
+ },
899
+ },
900
+ },
901
+ "property": "description",
902
+ },
903
+ Object {
904
+ "cell": Object {
905
+ "formatters": Array [
906
+ null,
907
+ ],
908
+ },
909
+ "header": Object {
910
+ "formatters": Array [
911
+ null,
912
+ ],
913
+ "label": "Service",
914
+ "props": Object {
915
+ "index": 2,
916
+ "style": Object {
917
+ "width": "20%",
918
+ },
919
+ },
920
+ },
921
+ "property": "service",
922
+ },
923
+ Object {
924
+ "cell": Object {
925
+ "formatters": Array [
926
+ null,
927
+ ],
928
+ },
929
+ "header": Object {
930
+ "formatters": Array [
931
+ null,
932
+ ],
933
+ "label": "Actions",
934
+ "props": Object {
935
+ "index": 4,
936
+ "style": Object {
937
+ "width": "20%",
938
+ },
939
+ },
940
+ },
941
+ "property": "actions",
942
+ },
943
+ ],
944
+ "error": Object {
945
+ "errorMsg": "",
946
+ "status": "",
947
+ "statusText": "",
948
+ },
949
+ "hosts": Array [
950
+ Object {
951
+ "ansibleParameters": Array [
952
+ Object {
953
+ "id": 0,
954
+ "name": "mysqlservice",
955
+ "value": "mysqld",
956
+ },
957
+ Object {
958
+ "id": 1,
959
+ "name": "mysql_port",
960
+ "value": "3306",
961
+ },
962
+ Object {
963
+ "id": 2,
964
+ "name": "dbuser",
965
+ "value": "webapp",
966
+ },
967
+ Object {
968
+ "id": 3,
969
+ "name": "dbname",
970
+ "value": "ANSAP01",
971
+ },
972
+ Object {
973
+ "id": 4,
974
+ "name": "upassword",
975
+ "value": "Bond@007",
976
+ },
977
+ Object {
978
+ "id": 5,
979
+ "name": "masterpassword",
980
+ "value": "MySQL@007",
981
+ },
982
+ ],
983
+ "description": "",
984
+ "foremanParameters": Array [],
985
+ "hostname": "great-web-app-db-1",
986
+ "id": 4,
987
+ "service": "2",
988
+ },
989
+ Object {
990
+ "ansibleParameters": Array [
991
+ Object {
992
+ "id": 0,
993
+ "name": "dummy_var",
994
+ "value": "0",
995
+ },
996
+ ],
997
+ "description": "",
998
+ "foremanParameters": Array [],
999
+ "hostname": "great-web-app-web-1",
1000
+ "id": 1,
1001
+ "service": "1",
1002
+ },
1003
+ Object {
1004
+ "ansibleParameters": Array [
1005
+ Object {
1006
+ "id": 0,
1007
+ "name": "dummy_var",
1008
+ "value": "0",
1009
+ },
1010
+ ],
1011
+ "backup": Object {
1012
+ "ansibleParameters": Array [
1013
+ Object {
1014
+ "id": 0,
1015
+ "name": "dummy_var",
1016
+ "value": "0",
1017
+ },
1018
+ ],
1019
+ "description": "",
1020
+ "foremanParameters": Array [],
1021
+ "hostname": "great-web-app-web-2",
1022
+ "id": 2,
1023
+ "service": "1",
1024
+ },
1025
+ "description": "",
1026
+ "foremanParameters": Array [],
1027
+ "hostname": "great-web-app-web-2",
1028
+ "id": 2,
1029
+ "name": "helloworld",
1030
+ "service": "1",
1031
+ },
1032
+ ],
1033
+ "loading": false,
1034
+ "name": false,
1035
+ "services": Array [
1036
+ Object {
1037
+ "ansibleGroup": "webservers",
1038
+ "ansibleParameters": Array [
1039
+ Object {
1040
+ "id": 0,
1041
+ "name": "dummy_var",
1042
+ "value": "0",
1043
+ },
1044
+ ],
1045
+ "currentCount": 2,
1046
+ "description": "",
1047
+ "foremanParameters": Array [
1048
+ Object {
1049
+ "description": "",
1050
+ "id": 1,
1051
+ "locked": false,
1052
+ "name": "CP",
1053
+ "type": "computeprofile",
1054
+ "value": "1",
1055
+ },
1056
+ Object {
1057
+ "description": "",
1058
+ "id": 2,
1059
+ "locked": true,
1060
+ "name": "LE",
1061
+ "type": "lifecycleenv",
1062
+ "value": "1",
1063
+ },
1064
+ ],
1065
+ "hostgroup": "1",
1066
+ "id": 1,
1067
+ "maxCount": "",
1068
+ "minCount": "2",
1069
+ "name": "web",
1070
+ },
1071
+ Object {
1072
+ "ansibleGroup": "dbservers",
1073
+ "ansibleParameters": Array [
1074
+ Object {
1075
+ "id": 0,
1076
+ "name": "mysqlservice",
1077
+ "value": "mysqld",
1078
+ },
1079
+ Object {
1080
+ "id": 1,
1081
+ "locked": true,
1082
+ "name": "mysql_port",
1083
+ "value": "3306",
1084
+ },
1085
+ Object {
1086
+ "id": 2,
1087
+ "name": "dbuser",
1088
+ "value": "webapp",
1089
+ },
1090
+ Object {
1091
+ "id": 3,
1092
+ "name": "dbname",
1093
+ "value": "ANSAP01",
1094
+ },
1095
+ Object {
1096
+ "id": 4,
1097
+ "name": "upassword",
1098
+ "value": "Bond@007",
1099
+ },
1100
+ Object {
1101
+ "id": 5,
1102
+ "name": "masterpassword",
1103
+ "value": "MySQL@007",
1104
+ },
1105
+ ],
1106
+ "currentCount": 1,
1107
+ "description": "",
1108
+ "foremanParameters": Array [],
1109
+ "hostgroup": "1",
1110
+ "id": 2,
1111
+ "maxCount": "",
1112
+ "minCount": "1",
1113
+ "name": "db",
1114
+ },
1115
+ ],
1116
+ }
1117
+ `;
1118
+
1119
+ exports[`ApplicationInstanceReducer should close alert modal 1`] = `
1120
+ Object {
1121
+ "alertModalText": "",
1122
+ "alertModalTitle": "",
1123
+ "ansibleVarsAll": Array [
1124
+ Object {
1125
+ "id": 0,
1126
+ "name": "repository",
1127
+ "value": "https://github.com/bennojoy/mywebapp.git",
1128
+ },
1129
+ ],
1130
+ "appDefinition": Object {
1131
+ "ansible_vars_all": "[{\\"id\\":0,\\"name\\":\\"repository\\",\\"value\\":\\"https://github.com/bennojoy/mywebapp.git\\"}]",
1132
+ "created_at": "2021-03-11 12:51:34 +0100",
1133
+ "description": "",
1134
+ "id": 1,
1135
+ "location_ids": Array [
1136
+ 2,
1137
+ ],
1138
+ "name": "LAMP",
1139
+ "organization_ids": Array [
1140
+ 1,
1141
+ ],
1142
+ "services": "[{\\"id\\":1,\\"name\\":\\"web\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"webservers\\",\\"minCount\\":\\"2\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[{\\"id\\":1,\\"locked\\":false,\\"name\\":\\"CP\\",\\"description\\":\\"\\",\\"type\\":\\"computeprofile\\",\\"value\\":\\"1\\"},{\\"id\\":2,\\"locked\\":true,\\"name\\":\\"LE\\",\\"description\\":\\"\\",\\"type\\":\\"lifecycleenv\\",\\"value\\":\\"1\\"}],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"dummy_var\\",\\"value\\":\\"0\\"}]},{\\"id\\":2,\\"name\\":\\"db\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"dbservers\\",\\"minCount\\":\\"1\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"mysqlservice\\",\\"value\\":\\"mysqld\\"},{\\"id\\":1,\\"name\\":\\"mysql_port\\",\\"value\\":\\"3306\\",\\"locked\\":true},{\\"id\\":2,\\"name\\":\\"dbuser\\",\\"value\\":\\"webapp\\"},{\\"id\\":3,\\"name\\":\\"dbname\\",\\"value\\":\\"ANSAP01\\"},{\\"id\\":4,\\"name\\":\\"upassword\\",\\"value\\":\\"Bond@007\\"},{\\"id\\":5,\\"name\\":\\"masterpassword\\",\\"value\\":\\"MySQL@007\\"}]}]",
1143
+ "updated_at": "2021-03-13 00:06:12 +0100",
1144
+ },
1145
+ "columns": Array [
1146
+ Object {
1147
+ "cell": Object {
1148
+ "formatters": Array [
1149
+ null,
1150
+ ],
1151
+ },
1152
+ "header": Object {
1153
+ "formatters": Array [
1154
+ null,
1155
+ ],
1156
+ "label": "Hostname",
1157
+ "props": Object {
1158
+ "index": 0,
1159
+ "style": Object {
1160
+ "width": "30%",
1161
+ },
1162
+ },
1163
+ },
1164
+ "property": "hostname",
1165
+ },
1166
+ Object {
1167
+ "cell": Object {
1168
+ "formatters": Array [
1169
+ null,
1170
+ ],
1171
+ },
1172
+ "header": Object {
1173
+ "formatters": Array [
1174
+ null,
1175
+ ],
1176
+ "label": "Description",
1177
+ "props": Object {
1178
+ "index": 1,
1179
+ "style": Object {
1180
+ "width": "30%",
1181
+ },
1182
+ },
1183
+ },
1184
+ "property": "description",
1185
+ },
1186
+ Object {
1187
+ "cell": Object {
1188
+ "formatters": Array [
1189
+ null,
1190
+ ],
1191
+ },
1192
+ "header": Object {
1193
+ "formatters": Array [
1194
+ null,
1195
+ ],
1196
+ "label": "Service",
1197
+ "props": Object {
1198
+ "index": 2,
1199
+ "style": Object {
1200
+ "width": "20%",
1201
+ },
1202
+ },
1203
+ },
1204
+ "property": "service",
1205
+ },
1206
+ Object {
1207
+ "cell": Object {
1208
+ "formatters": Array [
1209
+ null,
1210
+ ],
1211
+ },
1212
+ "header": Object {
1213
+ "formatters": Array [
1214
+ null,
1215
+ ],
1216
+ "label": "Actions",
1217
+ "props": Object {
1218
+ "index": 4,
1219
+ "style": Object {
1220
+ "width": "20%",
1221
+ },
1222
+ },
1223
+ },
1224
+ "property": "actions",
1225
+ },
1226
+ ],
1227
+ "error": Object {
1228
+ "errorMsg": "",
1229
+ "status": "",
1230
+ "statusText": "",
1231
+ },
1232
+ "hosts": Array [
1233
+ Object {
1234
+ "ansibleParameters": Array [
1235
+ Object {
1236
+ "id": 0,
1237
+ "name": "mysqlservice",
1238
+ "value": "mysqld",
1239
+ },
1240
+ Object {
1241
+ "id": 1,
1242
+ "name": "mysql_port",
1243
+ "value": "3306",
1244
+ },
1245
+ Object {
1246
+ "id": 2,
1247
+ "name": "dbuser",
1248
+ "value": "webapp",
1249
+ },
1250
+ Object {
1251
+ "id": 3,
1252
+ "name": "dbname",
1253
+ "value": "ANSAP01",
1254
+ },
1255
+ Object {
1256
+ "id": 4,
1257
+ "name": "upassword",
1258
+ "value": "Bond@007",
1259
+ },
1260
+ Object {
1261
+ "id": 5,
1262
+ "name": "masterpassword",
1263
+ "value": "MySQL@007",
1264
+ },
1265
+ ],
1266
+ "description": "",
1267
+ "foremanParameters": Array [],
1268
+ "hostname": "great-web-app-db-1",
1269
+ "id": 4,
1270
+ "service": "2",
1271
+ },
1272
+ Object {
1273
+ "ansibleParameters": Array [
1274
+ Object {
1275
+ "id": 0,
1276
+ "name": "dummy_var",
1277
+ "value": "0",
1278
+ },
1279
+ ],
1280
+ "description": "",
1281
+ "foremanParameters": Array [],
1282
+ "hostname": "great-web-app-web-1",
1283
+ "id": 1,
1284
+ "service": "1",
1285
+ },
1286
+ Object {
1287
+ "ansibleParameters": Array [
1288
+ Object {
1289
+ "id": 0,
1290
+ "name": "dummy_var",
1291
+ "value": "0",
1292
+ },
1293
+ ],
1294
+ "description": "",
1295
+ "foremanParameters": Array [],
1296
+ "hostname": "great-web-app-web-2",
1297
+ "id": 2,
1298
+ "service": "1",
1299
+ },
1300
+ ],
1301
+ "loading": false,
1302
+ "name": false,
1303
+ "services": Array [
1304
+ Object {
1305
+ "ansibleGroup": "webservers",
1306
+ "ansibleParameters": Array [
1307
+ Object {
1308
+ "id": 0,
1309
+ "name": "dummy_var",
1310
+ "value": "0",
1311
+ },
1312
+ ],
1313
+ "currentCount": 2,
1314
+ "description": "",
1315
+ "foremanParameters": Array [
1316
+ Object {
1317
+ "description": "",
1318
+ "id": 1,
1319
+ "locked": false,
1320
+ "name": "CP",
1321
+ "type": "computeprofile",
1322
+ "value": "1",
1323
+ },
1324
+ Object {
1325
+ "description": "",
1326
+ "id": 2,
1327
+ "locked": true,
1328
+ "name": "LE",
1329
+ "type": "lifecycleenv",
1330
+ "value": "1",
1331
+ },
1332
+ ],
1333
+ "hostgroup": "1",
1334
+ "id": 1,
1335
+ "maxCount": "",
1336
+ "minCount": "2",
1337
+ "name": "web",
1338
+ },
1339
+ Object {
1340
+ "ansibleGroup": "dbservers",
1341
+ "ansibleParameters": Array [
1342
+ Object {
1343
+ "id": 0,
1344
+ "name": "mysqlservice",
1345
+ "value": "mysqld",
1346
+ },
1347
+ Object {
1348
+ "id": 1,
1349
+ "locked": true,
1350
+ "name": "mysql_port",
1351
+ "value": "3306",
1352
+ },
1353
+ Object {
1354
+ "id": 2,
1355
+ "name": "dbuser",
1356
+ "value": "webapp",
1357
+ },
1358
+ Object {
1359
+ "id": 3,
1360
+ "name": "dbname",
1361
+ "value": "ANSAP01",
1362
+ },
1363
+ Object {
1364
+ "id": 4,
1365
+ "name": "upassword",
1366
+ "value": "Bond@007",
1367
+ },
1368
+ Object {
1369
+ "id": 5,
1370
+ "name": "masterpassword",
1371
+ "value": "MySQL@007",
1372
+ },
1373
+ ],
1374
+ "currentCount": 1,
1375
+ "description": "",
1376
+ "foremanParameters": Array [],
1377
+ "hostgroup": "1",
1378
+ "id": 2,
1379
+ "maxCount": "",
1380
+ "minCount": "1",
1381
+ "name": "db",
1382
+ },
1383
+ ],
1384
+ "showAlertModal": false,
1385
+ }
1386
+ `;
1387
+
1388
+ exports[`ApplicationInstanceReducer should confirm edit host 1`] = `
1389
+ Object {
1390
+ "ansibleVarsAll": Array [
1391
+ Object {
1392
+ "id": 0,
1393
+ "name": "repository",
1394
+ "value": "https://github.com/bennojoy/mywebapp.git",
1395
+ },
1396
+ ],
1397
+ "appDefinition": Object {
1398
+ "ansible_vars_all": "[{\\"id\\":0,\\"name\\":\\"repository\\",\\"value\\":\\"https://github.com/bennojoy/mywebapp.git\\"}]",
1399
+ "created_at": "2021-03-11 12:51:34 +0100",
1400
+ "description": "",
1401
+ "id": 1,
1402
+ "location_ids": Array [
1403
+ 2,
1404
+ ],
1405
+ "name": "LAMP",
1406
+ "organization_ids": Array [
1407
+ 1,
1408
+ ],
1409
+ "services": "[{\\"id\\":1,\\"name\\":\\"web\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"webservers\\",\\"minCount\\":\\"2\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[{\\"id\\":1,\\"locked\\":false,\\"name\\":\\"CP\\",\\"description\\":\\"\\",\\"type\\":\\"computeprofile\\",\\"value\\":\\"1\\"},{\\"id\\":2,\\"locked\\":true,\\"name\\":\\"LE\\",\\"description\\":\\"\\",\\"type\\":\\"lifecycleenv\\",\\"value\\":\\"1\\"}],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"dummy_var\\",\\"value\\":\\"0\\"}]},{\\"id\\":2,\\"name\\":\\"db\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"dbservers\\",\\"minCount\\":\\"1\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"mysqlservice\\",\\"value\\":\\"mysqld\\"},{\\"id\\":1,\\"name\\":\\"mysql_port\\",\\"value\\":\\"3306\\",\\"locked\\":true},{\\"id\\":2,\\"name\\":\\"dbuser\\",\\"value\\":\\"webapp\\"},{\\"id\\":3,\\"name\\":\\"dbname\\",\\"value\\":\\"ANSAP01\\"},{\\"id\\":4,\\"name\\":\\"upassword\\",\\"value\\":\\"Bond@007\\"},{\\"id\\":5,\\"name\\":\\"masterpassword\\",\\"value\\":\\"MySQL@007\\"}]}]",
1410
+ "updated_at": "2021-03-13 00:06:12 +0100",
1411
+ },
1412
+ "columns": Array [
1413
+ Object {
1414
+ "cell": Object {
1415
+ "formatters": Array [
1416
+ null,
1417
+ ],
1418
+ },
1419
+ "header": Object {
1420
+ "formatters": Array [
1421
+ null,
1422
+ ],
1423
+ "label": "Hostname",
1424
+ "props": Object {
1425
+ "index": 0,
1426
+ "style": Object {
1427
+ "width": "30%",
1428
+ },
1429
+ },
1430
+ },
1431
+ "property": "hostname",
1432
+ },
1433
+ Object {
1434
+ "cell": Object {
1435
+ "formatters": Array [
1436
+ null,
1437
+ ],
1438
+ },
1439
+ "header": Object {
1440
+ "formatters": Array [
1441
+ null,
1442
+ ],
1443
+ "label": "Description",
1444
+ "props": Object {
1445
+ "index": 1,
1446
+ "style": Object {
1447
+ "width": "30%",
1448
+ },
1449
+ },
1450
+ },
1451
+ "property": "description",
1452
+ },
1453
+ Object {
1454
+ "cell": Object {
1455
+ "formatters": Array [
1456
+ null,
1457
+ ],
1458
+ },
1459
+ "header": Object {
1460
+ "formatters": Array [
1461
+ null,
1462
+ ],
1463
+ "label": "Service",
1464
+ "props": Object {
1465
+ "index": 2,
1466
+ "style": Object {
1467
+ "width": "20%",
1468
+ },
1469
+ },
1470
+ },
1471
+ "property": "service",
1472
+ },
1473
+ Object {
1474
+ "cell": Object {
1475
+ "formatters": Array [
1476
+ null,
1477
+ ],
1478
+ },
1479
+ "header": Object {
1480
+ "formatters": Array [
1481
+ null,
1482
+ ],
1483
+ "label": "Actions",
1484
+ "props": Object {
1485
+ "index": 4,
1486
+ "style": Object {
1487
+ "width": "20%",
1488
+ },
1489
+ },
1490
+ },
1491
+ "property": "actions",
1492
+ },
1493
+ ],
1494
+ "editMode": false,
1495
+ "error": Object {
1496
+ "errorMsg": "",
1497
+ "status": "",
1498
+ "statusText": "",
1499
+ },
1500
+ "hosts": Array [
1501
+ Object {
1502
+ "ansibleParameters": Array [
1503
+ Object {
1504
+ "id": 0,
1505
+ "name": "mysqlservice",
1506
+ "value": "mysqld",
1507
+ },
1508
+ Object {
1509
+ "id": 1,
1510
+ "name": "mysql_port",
1511
+ "value": "3306",
1512
+ },
1513
+ Object {
1514
+ "id": 2,
1515
+ "name": "dbuser",
1516
+ "value": "webapp",
1517
+ },
1518
+ Object {
1519
+ "id": 3,
1520
+ "name": "dbname",
1521
+ "value": "ANSAP01",
1522
+ },
1523
+ Object {
1524
+ "id": 4,
1525
+ "name": "upassword",
1526
+ "value": "Bond@007",
1527
+ },
1528
+ Object {
1529
+ "id": 5,
1530
+ "name": "masterpassword",
1531
+ "value": "MySQL@007",
1532
+ },
1533
+ ],
1534
+ "description": "",
1535
+ "foremanParameters": Array [],
1536
+ "hostname": "great-web-app-db-1",
1537
+ "id": 4,
1538
+ "service": "2",
1539
+ },
1540
+ Object {
1541
+ "ansibleParameters": Array [
1542
+ Object {
1543
+ "id": 0,
1544
+ "name": "dummy_var",
1545
+ "value": "0",
1546
+ },
1547
+ ],
1548
+ "description": "",
1549
+ "foremanParameters": Array [],
1550
+ "hostname": "great-web-app-web-1",
1551
+ "id": 1,
1552
+ "service": "1",
1553
+ },
1554
+ Object {
1555
+ "ansibleParameters": Array [
1556
+ Object {
1557
+ "id": 0,
1558
+ "name": "dummy_var",
1559
+ "value": "0",
1560
+ },
1561
+ ],
1562
+ "description": "",
1563
+ "foremanParameters": Array [],
1564
+ "hostname": "great-web-app-web-2",
1565
+ "id": 2,
1566
+ "service": "1",
1567
+ },
1568
+ ],
1569
+ "loading": false,
1570
+ "name": false,
1571
+ "services": Array [
1572
+ Object {
1573
+ "ansibleGroup": "webservers",
1574
+ "ansibleParameters": Array [
1575
+ Object {
1576
+ "id": 0,
1577
+ "name": "dummy_var",
1578
+ "value": "0",
1579
+ },
1580
+ ],
1581
+ "currentCount": 2,
1582
+ "description": "",
1583
+ "foremanParameters": Array [
1584
+ Object {
1585
+ "description": "",
1586
+ "id": 1,
1587
+ "locked": false,
1588
+ "name": "CP",
1589
+ "type": "computeprofile",
1590
+ "value": "1",
1591
+ },
1592
+ Object {
1593
+ "description": "",
1594
+ "id": 2,
1595
+ "locked": true,
1596
+ "name": "LE",
1597
+ "type": "lifecycleenv",
1598
+ "value": "1",
1599
+ },
1600
+ ],
1601
+ "hostgroup": "1",
1602
+ "id": 1,
1603
+ "maxCount": "",
1604
+ "minCount": "2",
1605
+ "name": "web",
1606
+ },
1607
+ Object {
1608
+ "ansibleGroup": "dbservers",
1609
+ "ansibleParameters": Array [
1610
+ Object {
1611
+ "id": 0,
1612
+ "name": "mysqlservice",
1613
+ "value": "mysqld",
1614
+ },
1615
+ Object {
1616
+ "id": 1,
1617
+ "locked": true,
1618
+ "name": "mysql_port",
1619
+ "value": "3306",
1620
+ },
1621
+ Object {
1622
+ "id": 2,
1623
+ "name": "dbuser",
1624
+ "value": "webapp",
1625
+ },
1626
+ Object {
1627
+ "id": 3,
1628
+ "name": "dbname",
1629
+ "value": "ANSAP01",
1630
+ },
1631
+ Object {
1632
+ "id": 4,
1633
+ "name": "upassword",
1634
+ "value": "Bond@007",
1635
+ },
1636
+ Object {
1637
+ "id": 5,
1638
+ "name": "masterpassword",
1639
+ "value": "MySQL@007",
1640
+ },
1641
+ ],
1642
+ "currentCount": 1,
1643
+ "description": "",
1644
+ "foremanParameters": Array [],
1645
+ "hostgroup": "1",
1646
+ "id": 2,
1647
+ "maxCount": "",
1648
+ "minCount": "1",
1649
+ "name": "db",
1650
+ },
1651
+ ],
1652
+ }
1653
+ `;
1654
+
1655
+ exports[`ApplicationInstanceReducer should delete a host 1`] = `
1656
+ Object {
1657
+ "ansibleVarsAll": Array [
1658
+ Object {
1659
+ "id": 0,
1660
+ "name": "repository",
1661
+ "value": "https://github.com/bennojoy/mywebapp.git",
1662
+ },
1663
+ ],
1664
+ "appDefinition": Object {
1665
+ "ansible_vars_all": "[{\\"id\\":0,\\"name\\":\\"repository\\",\\"value\\":\\"https://github.com/bennojoy/mywebapp.git\\"}]",
1666
+ "created_at": "2021-03-11 12:51:34 +0100",
1667
+ "description": "",
1668
+ "id": 1,
1669
+ "location_ids": Array [
1670
+ 2,
1671
+ ],
1672
+ "name": "LAMP",
1673
+ "organization_ids": Array [
1674
+ 1,
1675
+ ],
1676
+ "services": "[{\\"id\\":1,\\"name\\":\\"web\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"webservers\\",\\"minCount\\":\\"2\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[{\\"id\\":1,\\"locked\\":false,\\"name\\":\\"CP\\",\\"description\\":\\"\\",\\"type\\":\\"computeprofile\\",\\"value\\":\\"1\\"},{\\"id\\":2,\\"locked\\":true,\\"name\\":\\"LE\\",\\"description\\":\\"\\",\\"type\\":\\"lifecycleenv\\",\\"value\\":\\"1\\"}],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"dummy_var\\",\\"value\\":\\"0\\"}]},{\\"id\\":2,\\"name\\":\\"db\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"dbservers\\",\\"minCount\\":\\"1\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"mysqlservice\\",\\"value\\":\\"mysqld\\"},{\\"id\\":1,\\"name\\":\\"mysql_port\\",\\"value\\":\\"3306\\",\\"locked\\":true},{\\"id\\":2,\\"name\\":\\"dbuser\\",\\"value\\":\\"webapp\\"},{\\"id\\":3,\\"name\\":\\"dbname\\",\\"value\\":\\"ANSAP01\\"},{\\"id\\":4,\\"name\\":\\"upassword\\",\\"value\\":\\"Bond@007\\"},{\\"id\\":5,\\"name\\":\\"masterpassword\\",\\"value\\":\\"MySQL@007\\"}]}]",
1677
+ "updated_at": "2021-03-13 00:06:12 +0100",
1678
+ },
1679
+ "columns": Array [
1680
+ Object {
1681
+ "cell": Object {
1682
+ "formatters": Array [
1683
+ null,
1684
+ ],
1685
+ },
1686
+ "header": Object {
1687
+ "formatters": Array [
1688
+ null,
1689
+ ],
1690
+ "label": "Hostname",
1691
+ "props": Object {
1692
+ "index": 0,
1693
+ "style": Object {
1694
+ "width": "30%",
1695
+ },
1696
+ },
1697
+ },
1698
+ "property": "hostname",
1699
+ },
1700
+ Object {
1701
+ "cell": Object {
1702
+ "formatters": Array [
1703
+ null,
1704
+ ],
1705
+ },
1706
+ "header": Object {
1707
+ "formatters": Array [
1708
+ null,
1709
+ ],
1710
+ "label": "Description",
1711
+ "props": Object {
1712
+ "index": 1,
1713
+ "style": Object {
1714
+ "width": "30%",
1715
+ },
1716
+ },
1717
+ },
1718
+ "property": "description",
1719
+ },
1720
+ Object {
1721
+ "cell": Object {
1722
+ "formatters": Array [
1723
+ null,
1724
+ ],
1725
+ },
1726
+ "header": Object {
1727
+ "formatters": Array [
1728
+ null,
1729
+ ],
1730
+ "label": "Service",
1731
+ "props": Object {
1732
+ "index": 2,
1733
+ "style": Object {
1734
+ "width": "20%",
1735
+ },
1736
+ },
1737
+ },
1738
+ "property": "service",
1739
+ },
1740
+ Object {
1741
+ "cell": Object {
1742
+ "formatters": Array [
1743
+ null,
1744
+ ],
1745
+ },
1746
+ "header": Object {
1747
+ "formatters": Array [
1748
+ null,
1749
+ ],
1750
+ "label": "Actions",
1751
+ "props": Object {
1752
+ "index": 4,
1753
+ "style": Object {
1754
+ "width": "20%",
1755
+ },
1756
+ },
1757
+ },
1758
+ "property": "actions",
1759
+ },
1760
+ ],
1761
+ "error": Object {
1762
+ "errorMsg": "",
1763
+ "status": "",
1764
+ "statusText": "",
1765
+ },
1766
+ "hosts": Array [
1767
+ Object {
1768
+ "ansibleParameters": Array [
1769
+ Object {
1770
+ "id": 0,
1771
+ "name": "mysqlservice",
1772
+ "value": "mysqld",
1773
+ },
1774
+ Object {
1775
+ "id": 1,
1776
+ "name": "mysql_port",
1777
+ "value": "3306",
1778
+ },
1779
+ Object {
1780
+ "id": 2,
1781
+ "name": "dbuser",
1782
+ "value": "webapp",
1783
+ },
1784
+ Object {
1785
+ "id": 3,
1786
+ "name": "dbname",
1787
+ "value": "ANSAP01",
1788
+ },
1789
+ Object {
1790
+ "id": 4,
1791
+ "name": "upassword",
1792
+ "value": "Bond@007",
1793
+ },
1794
+ Object {
1795
+ "id": 5,
1796
+ "name": "masterpassword",
1797
+ "value": "MySQL@007",
1798
+ },
1799
+ ],
1800
+ "description": "",
1801
+ "foremanParameters": Array [],
1802
+ "hostname": "great-web-app-db-1",
1803
+ "id": 4,
1804
+ "service": "2",
1805
+ },
1806
+ Object {
1807
+ "ansibleParameters": Array [
1808
+ Object {
1809
+ "id": 0,
1810
+ "name": "dummy_var",
1811
+ "value": "0",
1812
+ },
1813
+ ],
1814
+ "description": "",
1815
+ "foremanParameters": Array [],
1816
+ "hostname": "great-web-app-web-1",
1817
+ "id": 1,
1818
+ "service": "1",
1819
+ },
1820
+ ],
1821
+ "loading": false,
1822
+ "name": false,
1823
+ "services": Array [
1824
+ Object {
1825
+ "ansibleGroup": "webservers",
1826
+ "ansibleParameters": Array [
1827
+ Object {
1828
+ "id": 0,
1829
+ "name": "dummy_var",
1830
+ "value": "0",
1831
+ },
1832
+ ],
1833
+ "currentCount": 1,
1834
+ "description": "",
1835
+ "foremanParameters": Array [
1836
+ Object {
1837
+ "description": "",
1838
+ "id": 1,
1839
+ "locked": false,
1840
+ "name": "CP",
1841
+ "type": "computeprofile",
1842
+ "value": "1",
1843
+ },
1844
+ Object {
1845
+ "description": "",
1846
+ "id": 2,
1847
+ "locked": true,
1848
+ "name": "LE",
1849
+ "type": "lifecycleenv",
1850
+ "value": "1",
1851
+ },
1852
+ ],
1853
+ "hostgroup": "1",
1854
+ "id": 1,
1855
+ "maxCount": "",
1856
+ "minCount": "2",
1857
+ "name": "web",
1858
+ },
1859
+ Object {
1860
+ "ansibleGroup": "dbservers",
1861
+ "ansibleParameters": Array [
1862
+ Object {
1863
+ "id": 0,
1864
+ "name": "mysqlservice",
1865
+ "value": "mysqld",
1866
+ },
1867
+ Object {
1868
+ "id": 1,
1869
+ "locked": true,
1870
+ "name": "mysql_port",
1871
+ "value": "3306",
1872
+ },
1873
+ Object {
1874
+ "id": 2,
1875
+ "name": "dbuser",
1876
+ "value": "webapp",
1877
+ },
1878
+ Object {
1879
+ "id": 3,
1880
+ "name": "dbname",
1881
+ "value": "ANSAP01",
1882
+ },
1883
+ Object {
1884
+ "id": 4,
1885
+ "name": "upassword",
1886
+ "value": "Bond@007",
1887
+ },
1888
+ Object {
1889
+ "id": 5,
1890
+ "name": "masterpassword",
1891
+ "value": "MySQL@007",
1892
+ },
1893
+ ],
1894
+ "currentCount": 1,
1895
+ "description": "",
1896
+ "foremanParameters": Array [],
1897
+ "hostgroup": "1",
1898
+ "id": 2,
1899
+ "maxCount": "",
1900
+ "minCount": "1",
1901
+ "name": "db",
1902
+ },
1903
+ ],
1904
+ }
1905
+ `;
1906
+
1907
+ exports[`ApplicationInstanceReducer should initialize component 1`] = `
1908
+ Object {
1909
+ "ansibleVarsAll": Array [
1910
+ Object {
1911
+ "id": 0,
1912
+ "name": "repository",
1913
+ "value": "https://github.com/bennojoy/mywebapp.git",
1914
+ },
1915
+ ],
1916
+ "appDefinition": Object {
1917
+ "ansible_vars_all": "[{\\"id\\":0,\\"name\\":\\"repository\\",\\"value\\":\\"https://github.com/bennojoy/mywebapp.git\\"}]",
1918
+ "created_at": "2021-03-11 12:51:34 +0100",
1919
+ "description": "",
1920
+ "id": 1,
1921
+ "location_ids": Array [
1922
+ 2,
1923
+ ],
1924
+ "name": "LAMP",
1925
+ "organization_ids": Array [
1926
+ 1,
1927
+ ],
1928
+ "services": "[{\\"id\\":1,\\"name\\":\\"web\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"webservers\\",\\"minCount\\":\\"2\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[{\\"id\\":1,\\"locked\\":false,\\"name\\":\\"CP\\",\\"description\\":\\"\\",\\"type\\":\\"computeprofile\\",\\"value\\":\\"1\\"},{\\"id\\":2,\\"locked\\":true,\\"name\\":\\"LE\\",\\"description\\":\\"\\",\\"type\\":\\"lifecycleenv\\",\\"value\\":\\"1\\"}],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"dummy_var\\",\\"value\\":\\"0\\"}]},{\\"id\\":2,\\"name\\":\\"db\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"dbservers\\",\\"minCount\\":\\"1\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"mysqlservice\\",\\"value\\":\\"mysqld\\"},{\\"id\\":1,\\"name\\":\\"mysql_port\\",\\"value\\":\\"3306\\",\\"locked\\":true},{\\"id\\":2,\\"name\\":\\"dbuser\\",\\"value\\":\\"webapp\\"},{\\"id\\":3,\\"name\\":\\"dbname\\",\\"value\\":\\"ANSAP01\\"},{\\"id\\":4,\\"name\\":\\"upassword\\",\\"value\\":\\"Bond@007\\"},{\\"id\\":5,\\"name\\":\\"masterpassword\\",\\"value\\":\\"MySQL@007\\"}]}]",
1929
+ "updated_at": "2021-03-13 00:06:12 +0100",
1930
+ },
1931
+ "columns": Array [
1932
+ Object {
1933
+ "cell": Object {
1934
+ "formatters": Array [
1935
+ null,
1936
+ ],
1937
+ },
1938
+ "header": Object {
1939
+ "formatters": Array [
1940
+ null,
1941
+ ],
1942
+ "label": "Hostname",
1943
+ "props": Object {
1944
+ "index": 0,
1945
+ "style": Object {
1946
+ "width": "30%",
1947
+ },
1948
+ },
1949
+ },
1950
+ "property": "hostname",
1951
+ },
1952
+ Object {
1953
+ "cell": Object {
1954
+ "formatters": Array [
1955
+ null,
1956
+ ],
1957
+ },
1958
+ "header": Object {
1959
+ "formatters": Array [
1960
+ null,
1961
+ ],
1962
+ "label": "Description",
1963
+ "props": Object {
1964
+ "index": 1,
1965
+ "style": Object {
1966
+ "width": "30%",
1967
+ },
1968
+ },
1969
+ },
1970
+ "property": "description",
1971
+ },
1972
+ Object {
1973
+ "cell": Object {
1974
+ "formatters": Array [
1975
+ null,
1976
+ ],
1977
+ },
1978
+ "header": Object {
1979
+ "formatters": Array [
1980
+ null,
1981
+ ],
1982
+ "label": "Service",
1983
+ "props": Object {
1984
+ "index": 2,
1985
+ "style": Object {
1986
+ "width": "20%",
1987
+ },
1988
+ },
1989
+ },
1990
+ "property": "service",
1991
+ },
1992
+ Object {
1993
+ "cell": Object {
1994
+ "formatters": Array [
1995
+ null,
1996
+ ],
1997
+ },
1998
+ "header": Object {
1999
+ "formatters": Array [
2000
+ null,
2001
+ ],
2002
+ "label": "Actions",
2003
+ "props": Object {
2004
+ "index": 4,
2005
+ "style": Object {
2006
+ "width": "20%",
2007
+ },
2008
+ },
2009
+ },
2010
+ "property": "actions",
2011
+ },
2012
+ ],
2013
+ "error": Object {
2014
+ "errorMsg": "",
2015
+ "status": "",
2016
+ "statusText": "",
2017
+ },
2018
+ "hosts": Array [
2019
+ Object {
2020
+ "ansibleParameters": Array [
2021
+ Object {
2022
+ "id": 0,
2023
+ "name": "mysqlservice",
2024
+ "value": "mysqld",
2025
+ },
2026
+ Object {
2027
+ "id": 1,
2028
+ "name": "mysql_port",
2029
+ "value": "3306",
2030
+ },
2031
+ Object {
2032
+ "id": 2,
2033
+ "name": "dbuser",
2034
+ "value": "webapp",
2035
+ },
2036
+ Object {
2037
+ "id": 3,
2038
+ "name": "dbname",
2039
+ "value": "ANSAP01",
2040
+ },
2041
+ Object {
2042
+ "id": 4,
2043
+ "name": "upassword",
2044
+ "value": "Bond@007",
2045
+ },
2046
+ Object {
2047
+ "id": 5,
2048
+ "name": "masterpassword",
2049
+ "value": "MySQL@007",
2050
+ },
2051
+ ],
2052
+ "description": "",
2053
+ "foremanParameters": Array [],
2054
+ "hostname": "great-web-app-db-1",
2055
+ "id": 4,
2056
+ "service": "2",
2057
+ },
2058
+ Object {
2059
+ "ansibleParameters": Array [
2060
+ Object {
2061
+ "id": 0,
2062
+ "name": "dummy_var",
2063
+ "value": "0",
2064
+ },
2065
+ ],
2066
+ "description": "",
2067
+ "foremanParameters": Array [],
2068
+ "hostname": "great-web-app-web-1",
2069
+ "id": 1,
2070
+ "service": "1",
2071
+ },
2072
+ Object {
2073
+ "ansibleParameters": Array [
2074
+ Object {
2075
+ "id": 0,
2076
+ "name": "dummy_var",
2077
+ "value": "0",
2078
+ },
2079
+ ],
2080
+ "backup": Object {
2081
+ "ansibleParameters": Array [
2082
+ Object {
2083
+ "id": 0,
2084
+ "name": "dummy_var",
2085
+ "value": "0",
2086
+ },
2087
+ ],
2088
+ "description": "",
2089
+ "foremanParameters": Array [],
2090
+ "hostname": "great-web-app-web-2",
2091
+ "id": 2,
2092
+ "service": "1",
2093
+ },
2094
+ "description": "",
2095
+ "foremanParameters": Array [],
2096
+ "hostname": "great-web-app-web-2",
2097
+ "id": 2,
2098
+ "service": "1",
2099
+ },
2100
+ ],
2101
+ "loading": false,
2102
+ "name": false,
2103
+ "services": Array [
2104
+ Object {
2105
+ "ansibleGroup": "webservers",
2106
+ "ansibleParameters": Array [
2107
+ Object {
2108
+ "id": 0,
2109
+ "name": "dummy_var",
2110
+ "value": "0",
2111
+ },
2112
+ ],
2113
+ "currentCount": 2,
2114
+ "description": "",
2115
+ "foremanParameters": Array [
2116
+ Object {
2117
+ "description": "",
2118
+ "id": 1,
2119
+ "locked": false,
2120
+ "name": "CP",
2121
+ "type": "computeprofile",
2122
+ "value": "1",
2123
+ },
2124
+ Object {
2125
+ "description": "",
2126
+ "id": 2,
2127
+ "locked": true,
2128
+ "name": "LE",
2129
+ "type": "lifecycleenv",
2130
+ "value": "1",
2131
+ },
2132
+ ],
2133
+ "hostgroup": "1",
2134
+ "id": 1,
2135
+ "maxCount": "",
2136
+ "minCount": "2",
2137
+ "name": "web",
2138
+ },
2139
+ Object {
2140
+ "ansibleGroup": "dbservers",
2141
+ "ansibleParameters": Array [
2142
+ Object {
2143
+ "id": 0,
2144
+ "name": "mysqlservice",
2145
+ "value": "mysqld",
2146
+ },
2147
+ Object {
2148
+ "id": 1,
2149
+ "locked": true,
2150
+ "name": "mysql_port",
2151
+ "value": "3306",
2152
+ },
2153
+ Object {
2154
+ "id": 2,
2155
+ "name": "dbuser",
2156
+ "value": "webapp",
2157
+ },
2158
+ Object {
2159
+ "id": 3,
2160
+ "name": "dbname",
2161
+ "value": "ANSAP01",
2162
+ },
2163
+ Object {
2164
+ "id": 4,
2165
+ "name": "upassword",
2166
+ "value": "Bond@007",
2167
+ },
2168
+ Object {
2169
+ "id": 5,
2170
+ "name": "masterpassword",
2171
+ "value": "MySQL@007",
2172
+ },
2173
+ ],
2174
+ "currentCount": 1,
2175
+ "description": "",
2176
+ "foremanParameters": Array [],
2177
+ "hostgroup": "1",
2178
+ "id": 2,
2179
+ "maxCount": "",
2180
+ "minCount": "1",
2181
+ "name": "db",
2182
+ },
2183
+ ],
2184
+ }
2185
+ `;
2186
+
2187
+ exports[`ApplicationInstanceReducer should load param data be erroneous 1`] = `
2188
+ Object {
2189
+ "ansibleVarsAll": Array [
2190
+ Object {
2191
+ "id": 0,
2192
+ "name": "repository",
2193
+ "value": "https://github.com/bennojoy/mywebapp.git",
2194
+ },
2195
+ ],
2196
+ "appDefinition": Object {
2197
+ "ansible_vars_all": "[{\\"id\\":0,\\"name\\":\\"repository\\",\\"value\\":\\"https://github.com/bennojoy/mywebapp.git\\"}]",
2198
+ "created_at": "2021-03-11 12:51:34 +0100",
2199
+ "description": "",
2200
+ "id": 1,
2201
+ "location_ids": Array [
2202
+ 2,
2203
+ ],
2204
+ "name": "LAMP",
2205
+ "organization_ids": Array [
2206
+ 1,
2207
+ ],
2208
+ "services": "[{\\"id\\":1,\\"name\\":\\"web\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"webservers\\",\\"minCount\\":\\"2\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[{\\"id\\":1,\\"locked\\":false,\\"name\\":\\"CP\\",\\"description\\":\\"\\",\\"type\\":\\"computeprofile\\",\\"value\\":\\"1\\"},{\\"id\\":2,\\"locked\\":true,\\"name\\":\\"LE\\",\\"description\\":\\"\\",\\"type\\":\\"lifecycleenv\\",\\"value\\":\\"1\\"}],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"dummy_var\\",\\"value\\":\\"0\\"}]},{\\"id\\":2,\\"name\\":\\"db\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"dbservers\\",\\"minCount\\":\\"1\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"mysqlservice\\",\\"value\\":\\"mysqld\\"},{\\"id\\":1,\\"name\\":\\"mysql_port\\",\\"value\\":\\"3306\\",\\"locked\\":true},{\\"id\\":2,\\"name\\":\\"dbuser\\",\\"value\\":\\"webapp\\"},{\\"id\\":3,\\"name\\":\\"dbname\\",\\"value\\":\\"ANSAP01\\"},{\\"id\\":4,\\"name\\":\\"upassword\\",\\"value\\":\\"Bond@007\\"},{\\"id\\":5,\\"name\\":\\"masterpassword\\",\\"value\\":\\"MySQL@007\\"}]}]",
2209
+ "updated_at": "2021-03-13 00:06:12 +0100",
2210
+ },
2211
+ "columns": Array [
2212
+ Object {
2213
+ "cell": Object {
2214
+ "formatters": Array [
2215
+ null,
2216
+ ],
2217
+ },
2218
+ "header": Object {
2219
+ "formatters": Array [
2220
+ null,
2221
+ ],
2222
+ "label": "Hostname",
2223
+ "props": Object {
2224
+ "index": 0,
2225
+ "style": Object {
2226
+ "width": "30%",
2227
+ },
2228
+ },
2229
+ },
2230
+ "property": "hostname",
2231
+ },
2232
+ Object {
2233
+ "cell": Object {
2234
+ "formatters": Array [
2235
+ null,
2236
+ ],
2237
+ },
2238
+ "header": Object {
2239
+ "formatters": Array [
2240
+ null,
2241
+ ],
2242
+ "label": "Description",
2243
+ "props": Object {
2244
+ "index": 1,
2245
+ "style": Object {
2246
+ "width": "30%",
2247
+ },
2248
+ },
2249
+ },
2250
+ "property": "description",
2251
+ },
2252
+ Object {
2253
+ "cell": Object {
2254
+ "formatters": Array [
2255
+ null,
2256
+ ],
2257
+ },
2258
+ "header": Object {
2259
+ "formatters": Array [
2260
+ null,
2261
+ ],
2262
+ "label": "Service",
2263
+ "props": Object {
2264
+ "index": 2,
2265
+ "style": Object {
2266
+ "width": "20%",
2267
+ },
2268
+ },
2269
+ },
2270
+ "property": "service",
2271
+ },
2272
+ Object {
2273
+ "cell": Object {
2274
+ "formatters": Array [
2275
+ null,
2276
+ ],
2277
+ },
2278
+ "header": Object {
2279
+ "formatters": Array [
2280
+ null,
2281
+ ],
2282
+ "label": "Actions",
2283
+ "props": Object {
2284
+ "index": 4,
2285
+ "style": Object {
2286
+ "width": "20%",
2287
+ },
2288
+ },
2289
+ },
2290
+ "property": "actions",
2291
+ },
2292
+ ],
2293
+ "error": "Something really bad happend",
2294
+ "hosts": Array [
2295
+ Object {
2296
+ "ansibleParameters": Array [
2297
+ Object {
2298
+ "id": 0,
2299
+ "name": "mysqlservice",
2300
+ "value": "mysqld",
2301
+ },
2302
+ Object {
2303
+ "id": 1,
2304
+ "name": "mysql_port",
2305
+ "value": "3306",
2306
+ },
2307
+ Object {
2308
+ "id": 2,
2309
+ "name": "dbuser",
2310
+ "value": "webapp",
2311
+ },
2312
+ Object {
2313
+ "id": 3,
2314
+ "name": "dbname",
2315
+ "value": "ANSAP01",
2316
+ },
2317
+ Object {
2318
+ "id": 4,
2319
+ "name": "upassword",
2320
+ "value": "Bond@007",
2321
+ },
2322
+ Object {
2323
+ "id": 5,
2324
+ "name": "masterpassword",
2325
+ "value": "MySQL@007",
2326
+ },
2327
+ ],
2328
+ "description": "",
2329
+ "foremanParameters": Array [],
2330
+ "hostname": "great-web-app-db-1",
2331
+ "id": 4,
2332
+ "service": "2",
2333
+ },
2334
+ Object {
2335
+ "ansibleParameters": Array [
2336
+ Object {
2337
+ "id": 0,
2338
+ "name": "dummy_var",
2339
+ "value": "0",
2340
+ },
2341
+ ],
2342
+ "description": "",
2343
+ "foremanParameters": Array [],
2344
+ "hostname": "great-web-app-web-1",
2345
+ "id": 1,
2346
+ "service": "1",
2347
+ },
2348
+ Object {
2349
+ "ansibleParameters": Array [
2350
+ Object {
2351
+ "id": 0,
2352
+ "name": "dummy_var",
2353
+ "value": "0",
2354
+ },
2355
+ ],
2356
+ "description": "",
2357
+ "foremanParameters": Array [],
2358
+ "hostname": "great-web-app-web-2",
2359
+ "id": 2,
2360
+ "service": "1",
2361
+ },
2362
+ ],
2363
+ "loading": false,
2364
+ "name": false,
2365
+ "services": Array [
2366
+ Object {
2367
+ "ansibleGroup": "webservers",
2368
+ "ansibleParameters": Array [
2369
+ Object {
2370
+ "id": 0,
2371
+ "name": "dummy_var",
2372
+ "value": "0",
2373
+ },
2374
+ ],
2375
+ "currentCount": 2,
2376
+ "description": "",
2377
+ "foremanParameters": Array [
2378
+ Object {
2379
+ "description": "",
2380
+ "id": 1,
2381
+ "locked": false,
2382
+ "name": "CP",
2383
+ "type": "computeprofile",
2384
+ "value": "1",
2385
+ },
2386
+ Object {
2387
+ "description": "",
2388
+ "id": 2,
2389
+ "locked": true,
2390
+ "name": "LE",
2391
+ "type": "lifecycleenv",
2392
+ "value": "1",
2393
+ },
2394
+ ],
2395
+ "hostgroup": "1",
2396
+ "id": 1,
2397
+ "maxCount": "",
2398
+ "minCount": "2",
2399
+ "name": "web",
2400
+ },
2401
+ Object {
2402
+ "ansibleGroup": "dbservers",
2403
+ "ansibleParameters": Array [
2404
+ Object {
2405
+ "id": 0,
2406
+ "name": "mysqlservice",
2407
+ "value": "mysqld",
2408
+ },
2409
+ Object {
2410
+ "id": 1,
2411
+ "locked": true,
2412
+ "name": "mysql_port",
2413
+ "value": "3306",
2414
+ },
2415
+ Object {
2416
+ "id": 2,
2417
+ "name": "dbuser",
2418
+ "value": "webapp",
2419
+ },
2420
+ Object {
2421
+ "id": 3,
2422
+ "name": "dbname",
2423
+ "value": "ANSAP01",
2424
+ },
2425
+ Object {
2426
+ "id": 4,
2427
+ "name": "upassword",
2428
+ "value": "Bond@007",
2429
+ },
2430
+ Object {
2431
+ "id": 5,
2432
+ "name": "masterpassword",
2433
+ "value": "MySQL@007",
2434
+ },
2435
+ ],
2436
+ "currentCount": 1,
2437
+ "description": "",
2438
+ "foremanParameters": Array [],
2439
+ "hostgroup": "1",
2440
+ "id": 2,
2441
+ "maxCount": "",
2442
+ "minCount": "1",
2443
+ "name": "db",
2444
+ },
2445
+ ],
2446
+ }
2447
+ `;
2448
+
2449
+ exports[`ApplicationInstanceReducer should load param data be successful 1`] = `
2450
+ Object {
2451
+ "ansibleVarsAll": Array [
2452
+ Object {
2453
+ "id": 0,
2454
+ "name": "repository",
2455
+ "value": "https://github.com/bennojoy/mywebapp.git",
2456
+ },
2457
+ ],
2458
+ "appDefinition": Object {
2459
+ "ansible_vars_all": "[{\\"id\\":0,\\"name\\":\\"repository\\",\\"value\\":\\"https://github.com/bennojoy/mywebapp.git\\"}]",
2460
+ "created_at": "2021-03-11 12:51:34 +0100",
2461
+ "description": "",
2462
+ "id": 1,
2463
+ "location_ids": Array [
2464
+ 2,
2465
+ ],
2466
+ "name": "LAMP",
2467
+ "organization_ids": Array [
2468
+ 1,
2469
+ ],
2470
+ "services": "[{\\"id\\":1,\\"name\\":\\"web\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"webservers\\",\\"minCount\\":\\"2\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[{\\"id\\":1,\\"locked\\":false,\\"name\\":\\"CP\\",\\"description\\":\\"\\",\\"type\\":\\"computeprofile\\",\\"value\\":\\"1\\"},{\\"id\\":2,\\"locked\\":true,\\"name\\":\\"LE\\",\\"description\\":\\"\\",\\"type\\":\\"lifecycleenv\\",\\"value\\":\\"1\\"}],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"dummy_var\\",\\"value\\":\\"0\\"}]},{\\"id\\":2,\\"name\\":\\"db\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"dbservers\\",\\"minCount\\":\\"1\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"mysqlservice\\",\\"value\\":\\"mysqld\\"},{\\"id\\":1,\\"name\\":\\"mysql_port\\",\\"value\\":\\"3306\\",\\"locked\\":true},{\\"id\\":2,\\"name\\":\\"dbuser\\",\\"value\\":\\"webapp\\"},{\\"id\\":3,\\"name\\":\\"dbname\\",\\"value\\":\\"ANSAP01\\"},{\\"id\\":4,\\"name\\":\\"upassword\\",\\"value\\":\\"Bond@007\\"},{\\"id\\":5,\\"name\\":\\"masterpassword\\",\\"value\\":\\"MySQL@007\\"}]}]",
2471
+ "updated_at": "2021-03-13 00:06:12 +0100",
2472
+ },
2473
+ "columns": Array [
2474
+ Object {
2475
+ "cell": Object {
2476
+ "formatters": Array [
2477
+ null,
2478
+ ],
2479
+ },
2480
+ "header": Object {
2481
+ "formatters": Array [
2482
+ null,
2483
+ ],
2484
+ "label": "Hostname",
2485
+ "props": Object {
2486
+ "index": 0,
2487
+ "style": Object {
2488
+ "width": "30%",
2489
+ },
2490
+ },
2491
+ },
2492
+ "property": "hostname",
2493
+ },
2494
+ Object {
2495
+ "cell": Object {
2496
+ "formatters": Array [
2497
+ null,
2498
+ ],
2499
+ },
2500
+ "header": Object {
2501
+ "formatters": Array [
2502
+ null,
2503
+ ],
2504
+ "label": "Description",
2505
+ "props": Object {
2506
+ "index": 1,
2507
+ "style": Object {
2508
+ "width": "30%",
2509
+ },
2510
+ },
2511
+ },
2512
+ "property": "description",
2513
+ },
2514
+ Object {
2515
+ "cell": Object {
2516
+ "formatters": Array [
2517
+ null,
2518
+ ],
2519
+ },
2520
+ "header": Object {
2521
+ "formatters": Array [
2522
+ null,
2523
+ ],
2524
+ "label": "Service",
2525
+ "props": Object {
2526
+ "index": 2,
2527
+ "style": Object {
2528
+ "width": "20%",
2529
+ },
2530
+ },
2531
+ },
2532
+ "property": "service",
2533
+ },
2534
+ Object {
2535
+ "cell": Object {
2536
+ "formatters": Array [
2537
+ null,
2538
+ ],
2539
+ },
2540
+ "header": Object {
2541
+ "formatters": Array [
2542
+ null,
2543
+ ],
2544
+ "label": "Actions",
2545
+ "props": Object {
2546
+ "index": 4,
2547
+ "style": Object {
2548
+ "width": "20%",
2549
+ },
2550
+ },
2551
+ },
2552
+ "property": "actions",
2553
+ },
2554
+ ],
2555
+ "error": Object {
2556
+ "errorMsg": "",
2557
+ "status": "",
2558
+ "statusText": "",
2559
+ },
2560
+ "hosts": Array [
2561
+ Object {
2562
+ "ansibleParameters": Array [
2563
+ Object {
2564
+ "id": 0,
2565
+ "name": "mysqlservice",
2566
+ "value": "mysqld",
2567
+ },
2568
+ Object {
2569
+ "id": 1,
2570
+ "name": "mysql_port",
2571
+ "value": "3306",
2572
+ },
2573
+ Object {
2574
+ "id": 2,
2575
+ "name": "dbuser",
2576
+ "value": "webapp",
2577
+ },
2578
+ Object {
2579
+ "id": 3,
2580
+ "name": "dbname",
2581
+ "value": "ANSAP01",
2582
+ },
2583
+ Object {
2584
+ "id": 4,
2585
+ "name": "upassword",
2586
+ "value": "Bond@007",
2587
+ },
2588
+ Object {
2589
+ "id": 5,
2590
+ "name": "masterpassword",
2591
+ "value": "MySQL@007",
2592
+ },
2593
+ ],
2594
+ "description": "",
2595
+ "foremanParameters": Array [],
2596
+ "hostname": "great-web-app-db-1",
2597
+ "id": 4,
2598
+ "service": "2",
2599
+ },
2600
+ Object {
2601
+ "ansibleParameters": Array [
2602
+ Object {
2603
+ "id": 0,
2604
+ "name": "dummy_var",
2605
+ "value": "0",
2606
+ },
2607
+ ],
2608
+ "description": "",
2609
+ "foremanParameters": Array [],
2610
+ "hostname": "great-web-app-web-1",
2611
+ "id": 1,
2612
+ "service": "1",
2613
+ },
2614
+ Object {
2615
+ "ansibleParameters": Array [
2616
+ Object {
2617
+ "id": 0,
2618
+ "name": "dummy_var",
2619
+ "value": "0",
2620
+ },
2621
+ ],
2622
+ "description": "",
2623
+ "foremanParameters": Array [],
2624
+ "hostname": "great-web-app-web-2",
2625
+ "id": 2,
2626
+ "service": "1",
2627
+ },
2628
+ ],
2629
+ "loading": false,
2630
+ "name": false,
2631
+ "services": Array [
2632
+ Object {
2633
+ "ansibleGroup": "webservers",
2634
+ "ansibleParameters": Array [
2635
+ Object {
2636
+ "id": 0,
2637
+ "name": "dummy_var",
2638
+ "value": "0",
2639
+ },
2640
+ ],
2641
+ "currentCount": 2,
2642
+ "description": "",
2643
+ "foremanParameters": Array [
2644
+ Object {
2645
+ "description": "",
2646
+ "id": 1,
2647
+ "locked": false,
2648
+ "name": "CP",
2649
+ "type": "computeprofile",
2650
+ "value": "1",
2651
+ },
2652
+ Object {
2653
+ "description": "",
2654
+ "id": 2,
2655
+ "locked": true,
2656
+ "name": "LE",
2657
+ "type": "lifecycleenv",
2658
+ "value": "1",
2659
+ },
2660
+ ],
2661
+ "hostgroup": "1",
2662
+ "id": 1,
2663
+ "maxCount": "",
2664
+ "minCount": "2",
2665
+ "name": "web",
2666
+ },
2667
+ Object {
2668
+ "ansibleGroup": "dbservers",
2669
+ "ansibleParameters": Array [
2670
+ Object {
2671
+ "id": 0,
2672
+ "name": "mysqlservice",
2673
+ "value": "mysqld",
2674
+ },
2675
+ Object {
2676
+ "id": 1,
2677
+ "locked": true,
2678
+ "name": "mysql_port",
2679
+ "value": "3306",
2680
+ },
2681
+ Object {
2682
+ "id": 2,
2683
+ "name": "dbuser",
2684
+ "value": "webapp",
2685
+ },
2686
+ Object {
2687
+ "id": 3,
2688
+ "name": "dbname",
2689
+ "value": "ANSAP01",
2690
+ },
2691
+ Object {
2692
+ "id": 4,
2693
+ "name": "upassword",
2694
+ "value": "Bond@007",
2695
+ },
2696
+ Object {
2697
+ "id": 5,
2698
+ "name": "masterpassword",
2699
+ "value": "MySQL@007",
2700
+ },
2701
+ ],
2702
+ "currentCount": 1,
2703
+ "description": "",
2704
+ "foremanParameters": Array [],
2705
+ "hostgroup": "1",
2706
+ "id": 2,
2707
+ "maxCount": "",
2708
+ "minCount": "1",
2709
+ "name": "db",
2710
+ },
2711
+ ],
2712
+ }
2713
+ `;
2714
+
2715
+ exports[`ApplicationInstanceReducer should request load param data 1`] = `
2716
+ Object {
2717
+ "ansibleVarsAll": Array [
2718
+ Object {
2719
+ "id": 0,
2720
+ "name": "repository",
2721
+ "value": "https://github.com/bennojoy/mywebapp.git",
2722
+ },
2723
+ ],
2724
+ "appDefinition": Object {
2725
+ "ansible_vars_all": "[{\\"id\\":0,\\"name\\":\\"repository\\",\\"value\\":\\"https://github.com/bennojoy/mywebapp.git\\"}]",
2726
+ "created_at": "2021-03-11 12:51:34 +0100",
2727
+ "description": "",
2728
+ "id": 1,
2729
+ "location_ids": Array [
2730
+ 2,
2731
+ ],
2732
+ "name": "LAMP",
2733
+ "organization_ids": Array [
2734
+ 1,
2735
+ ],
2736
+ "services": "[{\\"id\\":1,\\"name\\":\\"web\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"webservers\\",\\"minCount\\":\\"2\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[{\\"id\\":1,\\"locked\\":false,\\"name\\":\\"CP\\",\\"description\\":\\"\\",\\"type\\":\\"computeprofile\\",\\"value\\":\\"1\\"},{\\"id\\":2,\\"locked\\":true,\\"name\\":\\"LE\\",\\"description\\":\\"\\",\\"type\\":\\"lifecycleenv\\",\\"value\\":\\"1\\"}],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"dummy_var\\",\\"value\\":\\"0\\"}]},{\\"id\\":2,\\"name\\":\\"db\\",\\"description\\":\\"\\",\\"hostgroup\\":\\"1\\",\\"ansibleGroup\\":\\"dbservers\\",\\"minCount\\":\\"1\\",\\"maxCount\\":\\"\\",\\"foremanParameters\\":[],\\"ansibleParameters\\":[{\\"id\\":0,\\"name\\":\\"mysqlservice\\",\\"value\\":\\"mysqld\\"},{\\"id\\":1,\\"name\\":\\"mysql_port\\",\\"value\\":\\"3306\\",\\"locked\\":true},{\\"id\\":2,\\"name\\":\\"dbuser\\",\\"value\\":\\"webapp\\"},{\\"id\\":3,\\"name\\":\\"dbname\\",\\"value\\":\\"ANSAP01\\"},{\\"id\\":4,\\"name\\":\\"upassword\\",\\"value\\":\\"Bond@007\\"},{\\"id\\":5,\\"name\\":\\"masterpassword\\",\\"value\\":\\"MySQL@007\\"}]}]",
2737
+ "updated_at": "2021-03-13 00:06:12 +0100",
2738
+ },
2739
+ "columns": Array [
2740
+ Object {
2741
+ "cell": Object {
2742
+ "formatters": Array [
2743
+ null,
2744
+ ],
2745
+ },
2746
+ "header": Object {
2747
+ "formatters": Array [
2748
+ null,
2749
+ ],
2750
+ "label": "Hostname",
2751
+ "props": Object {
2752
+ "index": 0,
2753
+ "style": Object {
2754
+ "width": "30%",
2755
+ },
2756
+ },
2757
+ },
2758
+ "property": "hostname",
2759
+ },
2760
+ Object {
2761
+ "cell": Object {
2762
+ "formatters": Array [
2763
+ null,
2764
+ ],
2765
+ },
2766
+ "header": Object {
2767
+ "formatters": Array [
2768
+ null,
2769
+ ],
2770
+ "label": "Description",
2771
+ "props": Object {
2772
+ "index": 1,
2773
+ "style": Object {
2774
+ "width": "30%",
2775
+ },
2776
+ },
2777
+ },
2778
+ "property": "description",
2779
+ },
2780
+ Object {
2781
+ "cell": Object {
2782
+ "formatters": Array [
2783
+ null,
2784
+ ],
2785
+ },
2786
+ "header": Object {
2787
+ "formatters": Array [
2788
+ null,
2789
+ ],
2790
+ "label": "Service",
2791
+ "props": Object {
2792
+ "index": 2,
2793
+ "style": Object {
2794
+ "width": "20%",
2795
+ },
2796
+ },
2797
+ },
2798
+ "property": "service",
2799
+ },
2800
+ Object {
2801
+ "cell": Object {
2802
+ "formatters": Array [
2803
+ null,
2804
+ ],
2805
+ },
2806
+ "header": Object {
2807
+ "formatters": Array [
2808
+ null,
2809
+ ],
2810
+ "label": "Actions",
2811
+ "props": Object {
2812
+ "index": 4,
2813
+ "style": Object {
2814
+ "width": "20%",
2815
+ },
2816
+ },
2817
+ },
2818
+ "property": "actions",
2819
+ },
2820
+ ],
2821
+ "error": Object {
2822
+ "errorMsg": "",
2823
+ "status": "",
2824
+ "statusText": "",
2825
+ },
2826
+ "hosts": Array [
2827
+ Object {
2828
+ "ansibleParameters": Array [
2829
+ Object {
2830
+ "id": 0,
2831
+ "name": "mysqlservice",
2832
+ "value": "mysqld",
2833
+ },
2834
+ Object {
2835
+ "id": 1,
2836
+ "name": "mysql_port",
2837
+ "value": "3306",
2838
+ },
2839
+ Object {
2840
+ "id": 2,
2841
+ "name": "dbuser",
2842
+ "value": "webapp",
2843
+ },
2844
+ Object {
2845
+ "id": 3,
2846
+ "name": "dbname",
2847
+ "value": "ANSAP01",
2848
+ },
2849
+ Object {
2850
+ "id": 4,
2851
+ "name": "upassword",
2852
+ "value": "Bond@007",
2853
+ },
2854
+ Object {
2855
+ "id": 5,
2856
+ "name": "masterpassword",
2857
+ "value": "MySQL@007",
2858
+ },
2859
+ ],
2860
+ "description": "",
2861
+ "foremanParameters": Array [],
2862
+ "hostname": "great-web-app-db-1",
2863
+ "id": 4,
2864
+ "service": "2",
2865
+ },
2866
+ Object {
2867
+ "ansibleParameters": Array [
2868
+ Object {
2869
+ "id": 0,
2870
+ "name": "dummy_var",
2871
+ "value": "0",
2872
+ },
2873
+ ],
2874
+ "description": "",
2875
+ "foremanParameters": Array [],
2876
+ "hostname": "great-web-app-web-1",
2877
+ "id": 1,
2878
+ "service": "1",
2879
+ },
2880
+ Object {
2881
+ "ansibleParameters": Array [
2882
+ Object {
2883
+ "id": 0,
2884
+ "name": "dummy_var",
2885
+ "value": "0",
2886
+ },
2887
+ ],
2888
+ "description": "",
2889
+ "foremanParameters": Array [],
2890
+ "hostname": "great-web-app-web-2",
2891
+ "id": 2,
2892
+ "service": "1",
2893
+ },
2894
+ ],
2895
+ "loading": true,
2896
+ "name": false,
2897
+ "services": Array [
2898
+ Object {
2899
+ "ansibleGroup": "webservers",
2900
+ "ansibleParameters": Array [
2901
+ Object {
2902
+ "id": 0,
2903
+ "name": "dummy_var",
2904
+ "value": "0",
2905
+ },
2906
+ ],
2907
+ "currentCount": 2,
2908
+ "description": "",
2909
+ "foremanParameters": Array [
2910
+ Object {
2911
+ "description": "",
2912
+ "id": 1,
2913
+ "locked": false,
2914
+ "name": "CP",
2915
+ "type": "computeprofile",
2916
+ "value": "1",
2917
+ },
2918
+ Object {
2919
+ "description": "",
2920
+ "id": 2,
2921
+ "locked": true,
2922
+ "name": "LE",
2923
+ "type": "lifecycleenv",
2924
+ "value": "1",
2925
+ },
2926
+ ],
2927
+ "hostgroup": "1",
2928
+ "id": 1,
2929
+ "maxCount": "",
2930
+ "minCount": "2",
2931
+ "name": "web",
2932
+ },
2933
+ Object {
2934
+ "ansibleGroup": "dbservers",
2935
+ "ansibleParameters": Array [
2936
+ Object {
2937
+ "id": 0,
2938
+ "name": "mysqlservice",
2939
+ "value": "mysqld",
2940
+ },
2941
+ Object {
2942
+ "id": 1,
2943
+ "locked": true,
2944
+ "name": "mysql_port",
2945
+ "value": "3306",
2946
+ },
2947
+ Object {
2948
+ "id": 2,
2949
+ "name": "dbuser",
2950
+ "value": "webapp",
2951
+ },
2952
+ Object {
2953
+ "id": 3,
2954
+ "name": "dbname",
2955
+ "value": "ANSAP01",
2956
+ },
2957
+ Object {
2958
+ "id": 4,
2959
+ "name": "upassword",
2960
+ "value": "Bond@007",
2961
+ },
2962
+ Object {
2963
+ "id": 5,
2964
+ "name": "masterpassword",
2965
+ "value": "MySQL@007",
2966
+ },
2967
+ ],
2968
+ "currentCount": 1,
2969
+ "description": "",
2970
+ "foremanParameters": Array [],
2971
+ "hostgroup": "1",
2972
+ "id": 2,
2973
+ "maxCount": "",
2974
+ "minCount": "1",
2975
+ "name": "db",
2976
+ },
2977
+ ],
2978
+ }
2979
+ `;
2980
+
2981
+ exports[`ApplicationInstanceReducer should return initial state 1`] = `
2982
+ Object {
2983
+ "error": Object {
2984
+ "errorMsg": "",
2985
+ "status": "",
2986
+ "statusText": "",
2987
+ },
2988
+ "name": false,
2989
+ }
2990
+ `;