@quadnix/octo 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +6 -1
- package/.eslintrc.cjs +0 -26
- package/dist/tsconfig.build.tsbuildinfo +0 -1
- package/src/app.type.ts +0 -56
- package/src/decorators/action.decorator.spec.ts +0 -43
- package/src/decorators/action.decorator.ts +0 -24
- package/src/decorators/anchor.decorator.ts +0 -10
- package/src/decorators/container.spec.ts +0 -104
- package/src/decorators/container.ts +0 -133
- package/src/decorators/factory.decorator.ts +0 -13
- package/src/decorators/model.decorator.ts +0 -10
- package/src/decorators/module.decorator.ts +0 -13
- package/src/decorators/overlay.decorator.ts +0 -10
- package/src/decorators/resource.decorator.ts +0 -10
- package/src/decorators/test-container.spec.ts +0 -50
- package/src/decorators/test-container.ts +0 -56
- package/src/functions/dependency/dependency.model.spec.ts +0 -43
- package/src/functions/dependency/dependency.model.ts +0 -178
- package/src/functions/diff/diff-metadata.model.ts +0 -51
- package/src/functions/diff/diff.model.ts +0 -33
- package/src/functions/diff/diff.utility.ts +0 -163
- package/src/functions/module/module.abstract.ts +0 -59
- package/src/functions/module/module.interface.ts +0 -5
- package/src/index.ts +0 -62
- package/src/models/action.interface.ts +0 -35
- package/src/models/app/app.interface.ts +0 -5
- package/src/models/app/app.model.ts +0 -111
- package/src/models/deployment/deployment.interface.ts +0 -5
- package/src/models/deployment/deployment.model.ts +0 -35
- package/src/models/environment/environment.interface.ts +0 -6
- package/src/models/environment/environment.model.spec.ts +0 -125
- package/src/models/environment/environment.model.ts +0 -55
- package/src/models/execution/execution.interface.ts +0 -8
- package/src/models/execution/execution.model.spec.ts +0 -62
- package/src/models/execution/execution.model.ts +0 -89
- package/src/models/image/image.interface.ts +0 -8
- package/src/models/image/image.model.ts +0 -62
- package/src/models/model.abstract.ts +0 -324
- package/src/models/model.interface.ts +0 -42
- package/src/models/pipeline/pipeline.interface.ts +0 -6
- package/src/models/pipeline/pipeline.model.ts +0 -47
- package/src/models/region/region.interface.ts +0 -5
- package/src/models/region/region.model.spec.ts +0 -162
- package/src/models/region/region.model.ts +0 -48
- package/src/models/server/server.interface.ts +0 -7
- package/src/models/server/server.model.ts +0 -56
- package/src/models/service/service.interface.ts +0 -5
- package/src/models/service/service.model.ts +0 -25
- package/src/models/support/support.interface.ts +0 -6
- package/src/models/support/support.model.spec.ts +0 -78
- package/src/models/support/support.model.ts +0 -52
- package/src/overlays/anchor.abstract.ts +0 -41
- package/src/overlays/anchor.interface.ts +0 -7
- package/src/overlays/anchor.spec.ts +0 -41
- package/src/overlays/overlay-data.repository.ts +0 -76
- package/src/overlays/overlay.abstract.ts +0 -64
- package/src/overlays/overlay.interface.ts +0 -9
- package/src/overlays/overlay.service.ts +0 -38
- package/src/overlays/overlay.spec.ts +0 -86
- package/src/resources/resource-action.interface.ts +0 -9
- package/src/resources/resource-data.repository.spec.ts +0 -133
- package/src/resources/resource-data.repository.ts +0 -92
- package/src/resources/resource.abstract.ts +0 -108
- package/src/resources/resource.interface.ts +0 -7
- package/src/resources/resource.spec.ts +0 -60
- package/src/resources/shared-resource.abstract.ts +0 -53
- package/src/resources/shared-resource.spec.ts +0 -133
- package/src/services/serialization/model/__snapshots__/model-serialization.service.spec.ts.snap +0 -656
- package/src/services/serialization/model/model-serialization.service.spec.ts +0 -195
- package/src/services/serialization/model/model-serialization.service.ts +0 -172
- package/src/services/serialization/resource/__snapshots__/resource-serialization.service.spec.ts.snap +0 -284
- package/src/services/serialization/resource/resource-serialization.service.spec.ts +0 -311
- package/src/services/serialization/resource/resource-serialization.service.ts +0 -166
- package/src/services/state-management/local.state-provider.spec.ts +0 -42
- package/src/services/state-management/local.state-provider.ts +0 -23
- package/src/services/state-management/state-management.service.ts +0 -43
- package/src/services/state-management/state-provider.interface.ts +0 -5
- package/src/services/transaction/__snapshots__/transaction.service.spec.ts.snap +0 -284
- package/src/services/transaction/transaction.service.spec.ts +0 -823
- package/src/services/transaction/transaction.service.ts +0 -386
- package/test/app.e2e-spec.ts +0 -104
- package/test/helpers/test-classes.ts +0 -31
- package/test/models/__snapshots__/model.e2e-spec.ts.snap +0 -451
- package/test/models/model.e2e-spec.ts +0 -366
- package/tsconfig.build.json +0 -4
- package/tsconfig.json +0 -9
|
@@ -1,284 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`TransactionService UT applyModels() should add the shared-resource to set of resources if it does not exist 1`] = `
|
|
4
|
-
[
|
|
5
|
-
"shared-resource",
|
|
6
|
-
]
|
|
7
|
-
`;
|
|
8
|
-
|
|
9
|
-
exports[`TransactionService UT applyModels() should call action and collect all input and output 1`] = `
|
|
10
|
-
[
|
|
11
|
-
[
|
|
12
|
-
{
|
|
13
|
-
"action": "add",
|
|
14
|
-
"field": "name",
|
|
15
|
-
"value": "app",
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
"input.key1": "value1",
|
|
19
|
-
},
|
|
20
|
-
],
|
|
21
|
-
]
|
|
22
|
-
`;
|
|
23
|
-
|
|
24
|
-
exports[`TransactionService UT applyModels() should call action and collect all input and output 2`] = `
|
|
25
|
-
[
|
|
26
|
-
"resource1",
|
|
27
|
-
]
|
|
28
|
-
`;
|
|
29
|
-
|
|
30
|
-
exports[`TransactionService UT applyModels() should call multiple actions and collect all input and output 1`] = `
|
|
31
|
-
[
|
|
32
|
-
[
|
|
33
|
-
{
|
|
34
|
-
"action": "add",
|
|
35
|
-
"field": "name",
|
|
36
|
-
"value": "app",
|
|
37
|
-
},
|
|
38
|
-
{
|
|
39
|
-
"input.key1": "value1",
|
|
40
|
-
},
|
|
41
|
-
],
|
|
42
|
-
]
|
|
43
|
-
`;
|
|
44
|
-
|
|
45
|
-
exports[`TransactionService UT applyModels() should call multiple actions and collect all input and output 2`] = `
|
|
46
|
-
[
|
|
47
|
-
[
|
|
48
|
-
{
|
|
49
|
-
"action": "add",
|
|
50
|
-
"field": "name",
|
|
51
|
-
"value": "app",
|
|
52
|
-
},
|
|
53
|
-
{
|
|
54
|
-
"input.key2": "value2",
|
|
55
|
-
},
|
|
56
|
-
],
|
|
57
|
-
]
|
|
58
|
-
`;
|
|
59
|
-
|
|
60
|
-
exports[`TransactionService UT applyModels() should call multiple actions and collect all input and output 3`] = `
|
|
61
|
-
[
|
|
62
|
-
"resource1",
|
|
63
|
-
"resource2",
|
|
64
|
-
]
|
|
65
|
-
`;
|
|
66
|
-
|
|
67
|
-
exports[`TransactionService UT applyModels() should merge the shared-resource with existing set of resources 1`] = `
|
|
68
|
-
[
|
|
69
|
-
"shared-resource",
|
|
70
|
-
]
|
|
71
|
-
`;
|
|
72
|
-
|
|
73
|
-
exports[`TransactionService UT applyModels() should only process 1 matching diff when duplicates found 1`] = `
|
|
74
|
-
[
|
|
75
|
-
[
|
|
76
|
-
{
|
|
77
|
-
"action": "add",
|
|
78
|
-
"field": "name",
|
|
79
|
-
"value": "app",
|
|
80
|
-
},
|
|
81
|
-
],
|
|
82
|
-
]
|
|
83
|
-
`;
|
|
84
|
-
|
|
85
|
-
exports[`TransactionService UT applyModels() should process diffs in different levels 1`] = `
|
|
86
|
-
[
|
|
87
|
-
[
|
|
88
|
-
{
|
|
89
|
-
"action": "add",
|
|
90
|
-
"field": "name",
|
|
91
|
-
"value": "app",
|
|
92
|
-
},
|
|
93
|
-
],
|
|
94
|
-
[
|
|
95
|
-
{
|
|
96
|
-
"action": "add",
|
|
97
|
-
"field": "regionId",
|
|
98
|
-
"value": "region",
|
|
99
|
-
},
|
|
100
|
-
],
|
|
101
|
-
]
|
|
102
|
-
`;
|
|
103
|
-
|
|
104
|
-
exports[`TransactionService UT applyModels() should return empty transaction if diffs is empty 1`] = `[]`;
|
|
105
|
-
|
|
106
|
-
exports[`TransactionService UT applyModels() should skip processing diffs that are already applied 1`] = `
|
|
107
|
-
[
|
|
108
|
-
[],
|
|
109
|
-
]
|
|
110
|
-
`;
|
|
111
|
-
|
|
112
|
-
exports[`TransactionService UT applyModels() should update diff metadata with inputs and outputs 1`] = `
|
|
113
|
-
{
|
|
114
|
-
"input.key1": "value1",
|
|
115
|
-
}
|
|
116
|
-
`;
|
|
117
|
-
|
|
118
|
-
exports[`TransactionService UT applyModels() should update diff metadata with inputs and outputs 2`] = `"resource1"`;
|
|
119
|
-
|
|
120
|
-
exports[`TransactionService UT applyResources() should only process 1 matching diff when duplicates found 1`] = `
|
|
121
|
-
[
|
|
122
|
-
[
|
|
123
|
-
{
|
|
124
|
-
"action": "add",
|
|
125
|
-
"field": "resourceId",
|
|
126
|
-
"value": "resource-1",
|
|
127
|
-
},
|
|
128
|
-
],
|
|
129
|
-
]
|
|
130
|
-
`;
|
|
131
|
-
|
|
132
|
-
exports[`TransactionService UT applyResources() should process diffs of adding resources per dependency graph 1`] = `
|
|
133
|
-
[
|
|
134
|
-
[
|
|
135
|
-
{
|
|
136
|
-
"action": "add",
|
|
137
|
-
"field": "resourceId",
|
|
138
|
-
"value": "resource-1",
|
|
139
|
-
},
|
|
140
|
-
],
|
|
141
|
-
[
|
|
142
|
-
{
|
|
143
|
-
"action": "add",
|
|
144
|
-
"field": "resourceId",
|
|
145
|
-
"value": "resource-2",
|
|
146
|
-
},
|
|
147
|
-
],
|
|
148
|
-
]
|
|
149
|
-
`;
|
|
150
|
-
|
|
151
|
-
exports[`TransactionService UT applyResources() should process diffs of deleting resources per dependency graph 1`] = `
|
|
152
|
-
[
|
|
153
|
-
[
|
|
154
|
-
{
|
|
155
|
-
"action": "delete",
|
|
156
|
-
"field": "resourceId",
|
|
157
|
-
"value": "resource-2",
|
|
158
|
-
},
|
|
159
|
-
],
|
|
160
|
-
[
|
|
161
|
-
{
|
|
162
|
-
"action": "delete",
|
|
163
|
-
"field": "resourceId",
|
|
164
|
-
"value": "resource-1",
|
|
165
|
-
},
|
|
166
|
-
],
|
|
167
|
-
]
|
|
168
|
-
`;
|
|
169
|
-
|
|
170
|
-
exports[`TransactionService UT applyResources() should return empty transaction if diffs is empty 1`] = `[]`;
|
|
171
|
-
|
|
172
|
-
exports[`TransactionService UT applyResources() should skip processing diffs that are already applied 1`] = `
|
|
173
|
-
[
|
|
174
|
-
[],
|
|
175
|
-
]
|
|
176
|
-
`;
|
|
177
|
-
|
|
178
|
-
exports[`TransactionService UT beginTransaction() yieldModelTransaction should yield model transaction 1`] = `
|
|
179
|
-
[
|
|
180
|
-
[
|
|
181
|
-
{
|
|
182
|
-
"action": "add",
|
|
183
|
-
"field": "name",
|
|
184
|
-
"value": "app",
|
|
185
|
-
},
|
|
186
|
-
],
|
|
187
|
-
]
|
|
188
|
-
`;
|
|
189
|
-
|
|
190
|
-
exports[`TransactionService UT beginTransaction() yieldModelTransaction should yield model transaction with overlays 1`] = `
|
|
191
|
-
[
|
|
192
|
-
[
|
|
193
|
-
{
|
|
194
|
-
"action": "add",
|
|
195
|
-
"field": "overlayId",
|
|
196
|
-
"value": "test-overlay",
|
|
197
|
-
},
|
|
198
|
-
],
|
|
199
|
-
]
|
|
200
|
-
`;
|
|
201
|
-
|
|
202
|
-
exports[`TransactionService UT beginTransaction() yieldResourceDiffs should yield resource diffs 1`] = `
|
|
203
|
-
[
|
|
204
|
-
[
|
|
205
|
-
{
|
|
206
|
-
"action": "delete",
|
|
207
|
-
"field": "resourceId",
|
|
208
|
-
"value": "resource-1",
|
|
209
|
-
},
|
|
210
|
-
{
|
|
211
|
-
"action": "add",
|
|
212
|
-
"field": "resourceId",
|
|
213
|
-
"value": "resource-2",
|
|
214
|
-
},
|
|
215
|
-
],
|
|
216
|
-
]
|
|
217
|
-
`;
|
|
218
|
-
|
|
219
|
-
exports[`TransactionService UT beginTransaction() yieldResourceTransaction should return model diffs 1`] = `
|
|
220
|
-
[
|
|
221
|
-
[
|
|
222
|
-
{
|
|
223
|
-
"action": "add",
|
|
224
|
-
"field": "name",
|
|
225
|
-
"value": "app",
|
|
226
|
-
},
|
|
227
|
-
],
|
|
228
|
-
]
|
|
229
|
-
`;
|
|
230
|
-
|
|
231
|
-
exports[`TransactionService UT beginTransaction() yieldResourceTransaction should yield resource diffs 1`] = `
|
|
232
|
-
[
|
|
233
|
-
[
|
|
234
|
-
{
|
|
235
|
-
"action": "delete",
|
|
236
|
-
"field": "resourceId",
|
|
237
|
-
"value": "resource-1",
|
|
238
|
-
},
|
|
239
|
-
{
|
|
240
|
-
"action": "add",
|
|
241
|
-
"field": "resourceId",
|
|
242
|
-
"value": "resource-2",
|
|
243
|
-
},
|
|
244
|
-
],
|
|
245
|
-
]
|
|
246
|
-
`;
|
|
247
|
-
|
|
248
|
-
exports[`TransactionService UT rollbackTransaction() should be able to revert addition of resources 1`] = `
|
|
249
|
-
[
|
|
250
|
-
[
|
|
251
|
-
{
|
|
252
|
-
"action": "delete",
|
|
253
|
-
"field": "resourceId",
|
|
254
|
-
"value": "resource-1",
|
|
255
|
-
},
|
|
256
|
-
],
|
|
257
|
-
]
|
|
258
|
-
`;
|
|
259
|
-
|
|
260
|
-
exports[`TransactionService UT rollbackTransaction() should be able to revert deletion of resources 1`] = `
|
|
261
|
-
[
|
|
262
|
-
[
|
|
263
|
-
{
|
|
264
|
-
"action": "add",
|
|
265
|
-
"field": "resourceId",
|
|
266
|
-
"value": "resource-1",
|
|
267
|
-
},
|
|
268
|
-
],
|
|
269
|
-
]
|
|
270
|
-
`;
|
|
271
|
-
|
|
272
|
-
exports[`TransactionService UT rollbackTransaction() should call revert() for every diff in transaction 1`] = `
|
|
273
|
-
[
|
|
274
|
-
[
|
|
275
|
-
{
|
|
276
|
-
"action": "add",
|
|
277
|
-
"field": "name",
|
|
278
|
-
"value": "app",
|
|
279
|
-
},
|
|
280
|
-
{},
|
|
281
|
-
{},
|
|
282
|
-
],
|
|
283
|
-
]
|
|
284
|
-
`;
|