@izara_project/izara-core-generate-service-code 1.0.18 → 1.0.20
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
CHANGED
|
@@ -60,7 +60,10 @@ async function data(_izContext, allIntTestConfig, srcPath) {
|
|
|
60
60
|
// 'testConfig.seedDataConfig[seedDataTag]',
|
|
61
61
|
// testConfig.seedDataConfig[seedDataTag]
|
|
62
62
|
// );
|
|
63
|
-
if (
|
|
63
|
+
if (
|
|
64
|
+
testConfig.seedDataConfig.hasOwnProperty(seedDataTag) &&
|
|
65
|
+
testConfig.seedDataConfig[seedDataTag].length > 0
|
|
66
|
+
) {
|
|
64
67
|
baseIntTest[seedDataTag] = testConfig.seedDataConfig[seedDataTag];
|
|
65
68
|
} else {
|
|
66
69
|
baseIntTest[seedDataTag] = [];
|
|
@@ -157,17 +160,25 @@ async function data(_izContext, allIntTestConfig, srcPath) {
|
|
|
157
160
|
);
|
|
158
161
|
if (dynamoEventStage.length > 0) {
|
|
159
162
|
// baseIntTest.stage[currentStageIdx]["dynamodbOutputEventIdentifiers"] = dynamoEventStage;
|
|
160
|
-
stages[currentStageIdx]['dynamodbOutputEventIdentifiers'] =
|
|
163
|
+
stages[currentStageIdx]['dynamodbOutputEventIdentifiers'] =
|
|
164
|
+
dynamoEventStage;
|
|
161
165
|
}
|
|
162
166
|
}
|
|
163
167
|
|
|
164
168
|
// generatedSeedData
|
|
165
|
-
if (
|
|
166
|
-
|
|
169
|
+
if (
|
|
170
|
+
stage.generatedSeedData &&
|
|
171
|
+
Object.keys(stage.generatedSeedData).length > 0
|
|
172
|
+
) {
|
|
173
|
+
for (const generateSeedType of Object.values(
|
|
174
|
+
GENERATE_SEED_DATA_TYPE
|
|
175
|
+
)) {
|
|
167
176
|
if (stage.generatedSeedData.hasOwnProperty(generateSeedType)) {
|
|
168
177
|
// baseIntTest.stage[currentStageIdx]["generateSeedDatas"] = {
|
|
169
|
-
stages[currentStageIdx]['
|
|
170
|
-
[generateSeedType]: [
|
|
178
|
+
stages[currentStageIdx]['generatedSeedData'] = {
|
|
179
|
+
[generateSeedType]: [
|
|
180
|
+
...stage.generatedSeedData[generateSeedType]
|
|
181
|
+
]
|
|
171
182
|
};
|
|
172
183
|
}
|
|
173
184
|
}
|
|
@@ -35,10 +35,6 @@ const templatePath = path.join(__dirname, 'template.ejs');
|
|
|
35
35
|
* @return {{templatePath, templateData,setting}}
|
|
36
36
|
*/
|
|
37
37
|
|
|
38
|
-
async function data(_izContext, flowSchema, srcPath) {
|
|
39
|
-
return [createSourceParams(_izContext, flowSchema, srcPath)];
|
|
40
|
-
}
|
|
41
|
-
|
|
42
38
|
function createSourceParams(_izContext, flowSchema, srcPath) {
|
|
43
39
|
let functionName = 'Process' + upperCase(flowSchema.flowTag);
|
|
44
40
|
let handlerType = upperCase(HANDLER.hdrSqs);
|
|
@@ -65,4 +61,4 @@ function createSourceParams(_izContext, flowSchema, srcPath) {
|
|
|
65
61
|
};
|
|
66
62
|
}
|
|
67
63
|
|
|
68
|
-
export default
|
|
64
|
+
export default createSourceParams;
|