@pega/custom-dx-components 0.25.18 → 0.25.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.
Files changed (71) hide show
  1. package/package.json +1 -1
  2. package/src/cli.js +6 -0
  3. package/src/constants.js +3 -1
  4. package/src/tasks/build-jest-assets/index.js +5 -5
  5. package/src/tasks/create-version/helper.js +30 -0
  6. package/src/tasks/create-version/index.js +12 -4
  7. package/src/tasks/delete-pub/helper.js +1 -1
  8. package/src/tasks/delete-pub/index.js +6 -1
  9. package/src/tasks/export-archive/helper.js +12 -12
  10. package/src/tasks/export-archive/index.js +6 -0
  11. package/src/tasks/import-archive/helper.js +205 -3
  12. package/src/tasks/import-archive/index.js +146 -31
  13. package/src/tasks/index.js +1 -0
  14. package/src/tasks/init/template/package.json.mustache +2 -1
  15. package/src/tasks/list-pub/helper.js +3 -3
  16. package/src/tasks/publish-archive/index.js +5 -2
  17. package/src/tasks/restore/index.js +72 -0
  18. package/src/tasks/show-help/index.js +25 -7
  19. package/src/tasks/show-status/index.js +10 -6
  20. package/src/util.js +58 -1
  21. package/tests/assets/library/components/create/Pega_DXIL_MyTestText/config.json +1 -1
  22. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyBoolean/config.json +1 -1
  23. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyCaseWidget/config.json +1 -1
  24. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyCaseWidget/localizations.json +8 -0
  25. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyCurrency/config.json +1 -1
  26. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyDate/config.json +1 -1
  27. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyDateTime/config.json +1 -1
  28. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyDecimal/config.json +1 -1
  29. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyDetails/config.json +1 -1
  30. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyEmail/config.json +1 -1
  31. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyForm/config.json +1 -1
  32. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyIconButtonURL/config.json +1 -1
  33. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyIconButtonURL/localizations.json +10 -0
  34. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyInteger/config.json +1 -1
  35. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPage/config.json +1 -1
  36. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPageCaseWidget/config.json +1 -1
  37. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPageWidget/config.json +1 -1
  38. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPageWidget/localizations.json +10 -0
  39. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyParagraph/config.json +1 -1
  40. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPercentage/config.json +1 -1
  41. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPhone/config.json +1 -1
  42. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPicklist/config.json +1 -1
  43. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyRadiobuttons/config.json +1 -1
  44. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MySearchbox/config.json +1 -1
  45. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MySearchbox/localizations.json +5 -0
  46. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyText/config.json +1 -1
  47. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyTextInput/config.json +1 -1
  48. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyTimeOfDay/config.json +1 -1
  49. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails/config.json +1 -1
  50. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyTwoColumnForm/config.json +1 -1
  51. package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyURL/config.json +1 -1
  52. package/tests/assets/original/components/createAll/Constellation/Pega_DXIL_MyCaseWidget/localizations.json +8 -0
  53. package/tests/assets/original/components/createAll/Constellation/Pega_DXIL_MyIconButtonURL/localizations.json +10 -0
  54. package/tests/assets/original/components/createAll/Constellation/Pega_DXIL_MyPageWidget/localizations.json +10 -0
  55. package/tests/assets/original/components/createAll/Constellation/Pega_DXIL_MySearchbox/localizations.json +5 -0
  56. package/tests/assets/original/components/createAll/Launchpad/Pega_DXIL_MySearchbox/localizations.json +5 -0
  57. package/tests/functional/localCreateAllListDeleteAll.test.js +8 -8
  58. package/tests/functional/localLibCreateLibAlreadyDeleteLib.test.js +14 -14
  59. package/tests/functional/localLibCreateLibBuildLibDeleteLib.test.js +17 -17
  60. package/tests/functional/localLibCreateLibBuildLibListPubDeleteLib.test.js +20 -20
  61. package/tests/functional/localLibCreateLibDeleteLib.test.js +17 -17
  62. package/tests/functional/localLibCreateLibExportImportLib.test.js +27 -27
  63. package/tests/functional/localLibCreateLibExportLib.test.js +19 -19
  64. package/tests/functional/localLibCreateLibImportCompDeleteLib.test.js +14 -14
  65. package/tests/functional/localLibCreateLibListDeleteLib.test.js +22 -22
  66. package/tests/functional/localLibCreateLibListMoveDeleteLib.test.js +31 -31
  67. package/tests/functional/localLibCreateLibListSwitchDeleteLib.test.js +20 -20
  68. package/tests/functional/localLibCreateLibStatusDeleteLib.test.js +13 -29
  69. package/tests/functional/localLibCreateLibValidateDeleteLib.test.js +15 -15
  70. package/tests/functional/localLibCreateLibVersionDeleteLib.test.js +27 -27
  71. package/tests/functional/localLibCreateLibPermDeleteLib.test.js +0 -144
@@ -3,7 +3,7 @@
3
3
  "label": "My Details",
4
4
  "description": "My Details",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyDetails",
@@ -3,7 +3,7 @@
3
3
  "label": "My Email",
4
4
  "description": "My Email",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyEmail",
@@ -3,7 +3,7 @@
3
3
  "label": "My Form",
4
4
  "description": "My Form",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyForm",
@@ -3,7 +3,7 @@
3
3
  "label": "My Icon Button URL",
4
4
  "description": "My Icon Button URL",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyIconButtonURL",
@@ -0,0 +1,10 @@
1
+ {
2
+ "fields": {
3
+ "State name" : "State name",
4
+ "State code" : "State code",
5
+ "State list for": "State list for",
6
+ "Click to show/hide state list": "Click to show/hide state list",
7
+ "State list": "State list",
8
+ "Loading state list": "Loading state list"
9
+ }
10
+ }
@@ -3,7 +3,7 @@
3
3
  "label": "My Integer",
4
4
  "description": "My Integer",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyInteger",
@@ -3,7 +3,7 @@
3
3
  "label": "My Page",
4
4
  "description": "My Page",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyPage",
@@ -3,7 +3,7 @@
3
3
  "label": "My PageCase Widget",
4
4
  "description": "My PageCase Widget",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyPageCaseWidget",
@@ -3,7 +3,7 @@
3
3
  "label": "My Page Widget",
4
4
  "description": "My Page Widget",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyPageWidget",
@@ -0,0 +1,10 @@
1
+ {
2
+ "fields": {
3
+ "Case type": "Case type",
4
+ "Key" : "Key",
5
+ "Status" : "Status",
6
+ "Stage" : "Stage",
7
+ "Work list" : "Work list",
8
+ "Loading Work list" : "Loading Work list"
9
+ }
10
+ }
@@ -3,7 +3,7 @@
3
3
  "label": "My Paragraph",
4
4
  "description": "My Paragraph",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyParagraph",
@@ -3,7 +3,7 @@
3
3
  "label": "My Percentage",
4
4
  "description": "My Percentage",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyPercentage",
@@ -3,7 +3,7 @@
3
3
  "label": "My Phone",
4
4
  "description": "My Phone",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyPhone",
@@ -3,7 +3,7 @@
3
3
  "label": "My Picklist",
4
4
  "description": "My Picklist",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyPicklist",
@@ -3,7 +3,7 @@
3
3
  "label": "My Radio buttons",
4
4
  "description": "My Radio buttons",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyRadiobuttons",
@@ -3,7 +3,7 @@
3
3
  "label": "My Search box",
4
4
  "description": "My Search box",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MySearchbox",
@@ -3,7 +3,7 @@
3
3
  "label": "My Text",
4
4
  "description": "My Text",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyText",
@@ -3,7 +3,7 @@
3
3
  "label": "My Text Input",
4
4
  "description": "My Text Input",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyTextInput",
@@ -3,7 +3,7 @@
3
3
  "label": "My TimeOfDay",
4
4
  "description": "My TimeOfDay",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyTimeOfDay",
@@ -3,7 +3,7 @@
3
3
  "label": "My Two Column Details",
4
4
  "description": "My Two Column Details",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyTwoColumnDetails",
@@ -3,7 +3,7 @@
3
3
  "label": "My Two Column Form",
4
4
  "description": "My Two Column Form",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyTwoColumnForm",
@@ -3,7 +3,7 @@
3
3
  "label": "My URL",
4
4
  "description": "My URL",
5
5
  "organization": "Pega",
6
- "version": "0.0.1-dev",
6
+ "version": "0.0.1",
7
7
  "library": "DXIL",
8
8
  "allowedApplications": [],
9
9
  "componentKey": "Pega_DXIL_MyURL",
@@ -0,0 +1,8 @@
1
+ {
2
+ "fields": {
3
+ "Date": "Date",
4
+ "Description" : "Description",
5
+ "Performed by" : "Performed by",
6
+ "Loading case history" : "Loading case history"
7
+ }
8
+ }
@@ -0,0 +1,10 @@
1
+ {
2
+ "fields": {
3
+ "State name" : "State name",
4
+ "State code" : "State code",
5
+ "State list for": "State list for",
6
+ "Click to show/hide state list": "Click to show/hide state list",
7
+ "State list": "State list",
8
+ "Loading state list": "Loading state list"
9
+ }
10
+ }
@@ -0,0 +1,10 @@
1
+ {
2
+ "fields": {
3
+ "Case type": "Case type",
4
+ "Key" : "Key",
5
+ "Status" : "Status",
6
+ "Stage" : "Stage",
7
+ "Work list" : "Work list",
8
+ "Loading Work list" : "Loading Work list"
9
+ }
10
+ }
@@ -12,13 +12,13 @@ const packageJSONDir = path.resolve('../../..', 'package.json');
12
12
  const packageJSONData = fs.readFileSync(packageJSONDir, { encoding: 'utf8'});
13
13
  let packageJSON = JSON.parse(packageJSONData);
14
14
 
15
- let isLibraryBased = tasksConfigJSON['libraryMode'];
16
- const savedLibraryBased = isLibraryBased;
15
+ let isLibraryBasedCL = tasksConfigJSON['libraryModeCL'];
16
+ const savedLibraryBased = isLibraryBasedCL;
17
17
  const savedOrganization = packageJSON.organization;
18
18
 
19
19
  const serverType = tasksConfigJSON['server-config'].serverType;
20
20
  const serverDir = serverType === 'launchpad' ? 'Launchpad' : 'Constellation';
21
- let compType = isLibraryBased ? "library" : "original";
21
+ let compType = isLibraryBasedCL ? "library" : "original";
22
22
 
23
23
 
24
24
  describe(`createAll list deleteAll local: ${serverDir} - ${compType}` , () => {
@@ -26,9 +26,9 @@ describe(`createAll list deleteAll local: ${serverDir} - ${compType}` , () => {
26
26
  beforeAll( async() => {
27
27
 
28
28
  // make non libraryBased
29
- isLibraryBased = false;
30
- tasksConfigJSON['libraryMode'] = isLibraryBased;
31
- compType = isLibraryBased ? "library" : "original";
29
+ isLibraryBasedCL = false;
30
+ tasksConfigJSON['libraryModeCL'] = isLibraryBasedCL;
31
+ compType = isLibraryBasedCL ? "library" : "original";
32
32
  fs.writeFileSync(tasksConfigDir, JSON.stringify(tasksConfigJSON, null, 4), { encoding: 'utf8' });
33
33
 
34
34
  // make organzation Pega
@@ -49,8 +49,8 @@ describe(`createAll list deleteAll local: ${serverDir} - ${compType}` , () => {
49
49
  afterAll( async() => {
50
50
 
51
51
  //restore
52
- isLibraryBased = savedLibraryBased
53
- tasksConfigJSON['libraryMode'] = isLibraryBased;
52
+ isLibraryBasedCL = savedLibraryBased
53
+ tasksConfigJSON['libraryModeCL'] = isLibraryBasedCL;
54
54
 
55
55
  fs.writeFileSync(tasksConfigDir, JSON.stringify(tasksConfigJSON, null, 4), { encoding: 'utf8' });
56
56
 
@@ -12,13 +12,13 @@ const packageJSONDir = path.resolve('../../..', 'package.json');
12
12
  const packageJSONData = fs.readFileSync(packageJSONDir, { encoding: 'utf8'});
13
13
  let packageJSON = JSON.parse(packageJSONData);
14
14
 
15
- let isLibraryBased = tasksConfigJSON['libraryMode'];
16
- const savedLibraryBased = isLibraryBased;
15
+ let isLibraryBasedCL = tasksConfigJSON['libraryModeCL'];
16
+ const savedLibraryBasedCL = isLibraryBasedCL;
17
17
  const savedOrganization = packageJSON.organization;
18
18
 
19
19
  const serverType = tasksConfigJSON['server-config'].serverType;
20
20
  const serverDir = serverType === 'launchpad' ? 'Launchpad' : 'Constellation';
21
- let compType = isLibraryBased ? "library" : "original";
21
+ let compType = isLibraryBasedCL ? "library" : "original";
22
22
 
23
23
 
24
24
  describe(`createLib createLib (already exists) deleteLib: ${serverDir} - ${compType}` , () => {
@@ -26,9 +26,9 @@ describe(`createLib createLib (already exists) deleteLib: ${serverDir} - ${compT
26
26
  beforeAll( async() => {
27
27
 
28
28
  // make libraryBased
29
- isLibraryBased = true;
30
- tasksConfigJSON['libraryMode'] = isLibraryBased;
31
- compType = isLibraryBased ? "library" : "original";
29
+ isLibraryBasedCL = true;
30
+ tasksConfigJSON['libraryModeCL'] = isLibraryBasedCL;
31
+ compType = isLibraryBasedCL ? "library" : "original";
32
32
  fs.writeFileSync(tasksConfigDir, JSON.stringify(tasksConfigJSON, null, 4), { encoding: 'utf8' });
33
33
 
34
34
  const storeDir = path.join(path.resolve('../../..'), 'store');
@@ -55,8 +55,8 @@ describe(`createLib createLib (already exists) deleteLib: ${serverDir} - ${compT
55
55
  afterAll( async() => {
56
56
 
57
57
  //restore
58
- isLibraryBased = savedLibraryBased
59
- tasksConfigJSON['libraryMode'] = isLibraryBased;
58
+ isLibraryBasedCL = savedLibraryBasedCL
59
+ tasksConfigJSON['libraryModeCL'] = isLibraryBasedCL;
60
60
 
61
61
  fs.writeFileSync(tasksConfigDir, JSON.stringify(tasksConfigJSON, null, 4), { encoding: 'utf8' });
62
62
 
@@ -80,14 +80,14 @@ describe(`createLib createLib (already exists) deleteLib: ${serverDir} - ${compT
80
80
  });
81
81
 
82
82
 
83
- it(`npm run createLib - ${isLibraryBased}`, async() => {
83
+ it(`npm run createLib - ${isLibraryBasedCL}`, async() => {
84
84
 
85
85
 
86
86
  const script = `npm run createLib DXIL 0.0.1 N Original --prefix ../../..`;
87
- const compConf = path.join("store", "Pega_DXIL","0.0.1-dev", "componentsconfig.json");
87
+ const compConf = path.join("store", "Pega_DXIL","0.0.1", "componentsconfig.json");
88
88
 
89
89
  const { stdout, stderr } = await exec(script);
90
- expect(stdout).toContain('Library Pega_DXIL/0.0.1-dev has been created!');
90
+ expect(stdout).toContain('Library Pega_DXIL/0.0.1 has been created!');
91
91
 
92
92
  const doesExist = fs.existsSync(path.resolve('../../..', compConf));
93
93
 
@@ -95,7 +95,7 @@ describe(`createLib createLib (already exists) deleteLib: ${serverDir} - ${compT
95
95
 
96
96
  }, 30000);
97
97
 
98
- it(`npm run createLib (already exists) - ${isLibraryBased}`, async() => {
98
+ it(`npm run createLib (already exists) - ${isLibraryBasedCL}`, async() => {
99
99
 
100
100
  const script = `npm run createLib DXIL 0.0.1 N Original --prefix ../../..`;
101
101
 
@@ -105,9 +105,9 @@ describe(`createLib createLib (already exists) deleteLib: ${serverDir} - ${compT
105
105
  }, 30000);
106
106
 
107
107
 
108
- it(`npm run deleteLib- ${isLibraryBased}`, async() => {
108
+ it(`npm run deleteLib- ${isLibraryBasedCL}`, async() => {
109
109
 
110
- const script = `npm run deleteLib Pega_DXIL 0.0.1-dev Y --prefix ../../..`;
110
+ const script = `npm run deleteLib Pega_DXIL 0.0.1 Y --prefix ../../..`;
111
111
  const { stdout, stderr } = await exec(script);
112
112
 
113
113
  expect(stdout).toContain('Pega_DXIL is deleted from Local.');
@@ -12,13 +12,13 @@ const packageJSONDir = path.resolve('../../..', 'package.json');
12
12
  const packageJSONData = fs.readFileSync(packageJSONDir, { encoding: 'utf8'});
13
13
  let packageJSON = JSON.parse(packageJSONData);
14
14
 
15
- let isLibraryBased = tasksConfigJSON['libraryMode'];
16
- const savedLibraryBased = isLibraryBased;
15
+ let isLIbraryBasedCL = tasksConfigJSON['libraryModeCL'];
16
+ const savedLibraryBased = isLIbraryBasedCL;
17
17
  const savedOrganization = packageJSON.organization;
18
18
 
19
19
  const serverType = tasksConfigJSON['server-config'].serverType;
20
20
  const serverDir = serverType === 'launchpad' ? 'Launchpad' : 'Constellation';
21
- let compType = isLibraryBased ? "library" : "original";
21
+ let compType = isLIbraryBasedCL ? "library" : "original";
22
22
 
23
23
 
24
24
  describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} - ${compType}` , () => {
@@ -26,9 +26,9 @@ describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} -
26
26
  beforeAll( async() => {
27
27
 
28
28
  // make libraryBased
29
- isLibraryBased = true;
30
- tasksConfigJSON['libraryMode'] = isLibraryBased;
31
- compType = isLibraryBased ? "library" : "original";
29
+ isLIbraryBasedCL = true;
30
+ tasksConfigJSON['libraryModeCL'] = isLIbraryBasedCL;
31
+ compType = isLIbraryBasedCL ? "library" : "original";
32
32
  fs.writeFileSync(tasksConfigDir, JSON.stringify(tasksConfigJSON, null, 4), { encoding: 'utf8' });
33
33
 
34
34
  const storeDir = path.join(path.resolve('../../..'), 'store');
@@ -54,8 +54,8 @@ describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} -
54
54
  afterAll( async() => {
55
55
 
56
56
  //restore
57
- isLibraryBased = savedLibraryBased
58
- tasksConfigJSON['libraryMode'] = isLibraryBased;
57
+ isLIbraryBasedCL = savedLibraryBased
58
+ tasksConfigJSON['libraryModeCL'] = isLIbraryBasedCL;
59
59
 
60
60
  fs.writeFileSync(tasksConfigDir, JSON.stringify(tasksConfigJSON, null, 4), { encoding: 'utf8' });
61
61
 
@@ -87,13 +87,13 @@ describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} -
87
87
  // }
88
88
  // });
89
89
 
90
- it(`npm run createLib - ${isLibraryBased}`, async() => {
90
+ it(`npm run createLib - ${isLIbraryBasedCL}`, async() => {
91
91
 
92
92
  const script = `npm run createLib DXIL 0.0.1 N Original --prefix ../../..`;
93
- const compConf = path.join("store", "Pega_DXIL","0.0.1-dev", "componentsconfig.json");
93
+ const compConf = path.join("store", "Pega_DXIL","0.0.1", "componentsconfig.json");
94
94
 
95
95
  const { stdout, stderr } = await exec(script);
96
- expect(stdout).toContain('Library Pega_DXIL/0.0.1-dev has been created!');
96
+ expect(stdout).toContain('Library Pega_DXIL/0.0.1 has been created!');
97
97
 
98
98
  const doesExist = fs.existsSync(path.resolve('../../..', compConf));
99
99
 
@@ -197,9 +197,9 @@ describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} -
197
197
  // }
198
198
  }, 10000);
199
199
 
200
- it(`npm run buildLib (internal) - ${isLibraryBased}`, async() => {
200
+ it(`npm run buildLib (internal) - ${isLIbraryBasedCL}`, async() => {
201
201
 
202
- const script = `npm run _internal-buildLibrary 0.0.1 Y --prefix ../../..`;
202
+ const script = `npm run _internal-buildLibrary 0.0.1 N --prefix ../../..`;
203
203
  const { stdout, stderr } = await exec(script);
204
204
 
205
205
  expect(stdout).toContain('Pega_DXIL_MyTestText schema is valid');
@@ -209,22 +209,22 @@ describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} -
209
209
  expect(stdout).toContain('Building Library...');
210
210
  expect(stdout).toContain('Compile check...');
211
211
 
212
- expect(stdout).toContain('Webpacked library Pega_DXIL:0.0.1-dev successfully!!');
212
+ expect(stdout).toContain('Webpacked library Pega_DXIL:0.0.1 successfully!!');
213
213
  expect(stdout).toContain('== Creating manifest for the library version - completed ==');
214
214
 
215
215
 
216
216
 
217
217
  }, 200000);
218
218
 
219
- it(`npm run deleteLib - ${isLibraryBased}`, async() => {
219
+ it(`npm run deleteLib - ${isLIbraryBasedCL}`, async() => {
220
220
 
221
- const script = `npm run deleteLib Pega_DXIL 0.0.1-dev Y --prefix ../../..`;
221
+ const script = `npm run deleteLib Pega_DXIL 0.0.1 Y --prefix ../../..`;
222
222
  const { stdout, stderr } = await exec(script);
223
223
  expect(stdout).toContain('Pega_DXIL is deleted from Local.');
224
224
 
225
225
  }, 30000);
226
226
 
227
- it(`npm run deletePublishedLib - ${isLibraryBased}`, async() => {
227
+ it(`npm run deletePublishedLib - ${isLIbraryBasedCL}`, async() => {
228
228
 
229
229
  const script = `npm run deletePublishedLib Local ALL --prefix ../../..`;
230
230
  const { stdout, stderr } = await exec(script);
@@ -13,13 +13,13 @@ const packageJSONDir = path.resolve('../../..', 'package.json');
13
13
  const packageJSONData = fs.readFileSync(packageJSONDir, { encoding: 'utf8'});
14
14
  let packageJSON = JSON.parse(packageJSONData);
15
15
 
16
- let isLibraryBased = tasksConfigJSON['libraryMode'];
17
- const savedLibraryBased = isLibraryBased;
16
+ let isLIbraryBasedC = tasksConfigJSON['libraryModeCL'];
17
+ const savedLibraryBased = isLIbraryBasedC;
18
18
  const savedOrganization = packageJSON.organization;
19
19
 
20
20
  const serverType = tasksConfigJSON['server-config'].serverType;
21
21
  const serverDir = serverType === 'launchpad' ? 'Launchpad' : 'Constellation';
22
- let compType = isLibraryBased ? "library" : "original";
22
+ let compType = isLIbraryBasedC ? "library" : "original";
23
23
 
24
24
 
25
25
  describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} - ${compType}` , () => {
@@ -27,9 +27,9 @@ describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} -
27
27
  beforeAll( async() => {
28
28
 
29
29
  // make libraryBased
30
- isLibraryBased = true;
31
- tasksConfigJSON['libraryMode'] = isLibraryBased;
32
- compType = isLibraryBased ? "library" : "original";
30
+ isLIbraryBasedC = true;
31
+ tasksConfigJSON['libraryModeCL'] = isLIbraryBasedC;
32
+ compType = isLIbraryBasedC ? "library" : "original";
33
33
  fs.writeFileSync(tasksConfigDir, JSON.stringify(tasksConfigJSON, null, 4), { encoding: 'utf8' });
34
34
 
35
35
  const storeDir = path.join(path.resolve('../../..'), 'store');
@@ -56,8 +56,8 @@ describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} -
56
56
  afterAll( async() => {
57
57
 
58
58
  //restore
59
- isLibraryBased = savedLibraryBased
60
- tasksConfigJSON['libraryMode'] = isLibraryBased;
59
+ isLIbraryBasedC = savedLibraryBased
60
+ tasksConfigJSON['libraryModeCL'] = isLIbraryBasedC;
61
61
 
62
62
  fs.writeFileSync(tasksConfigDir, JSON.stringify(tasksConfigJSON, null, 4), { encoding: 'utf8' });
63
63
 
@@ -76,13 +76,13 @@ describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} -
76
76
  });
77
77
 
78
78
 
79
- it(`npm run createLib - ${isLibraryBased}`, async() => {
79
+ it(`npm run createLib - ${isLIbraryBasedC}`, async() => {
80
80
 
81
81
  const script = `npm run createLib DXIL 0.0.1 N Original --prefix ../../..`;
82
- const compConf = path.join("store", "Pega_DXIL","0.0.1-dev", "componentsconfig.json");
82
+ const compConf = path.join("store", "Pega_DXIL","0.0.1", "componentsconfig.json");
83
83
 
84
84
  const { stdout, stderr } = await exec(script);
85
- expect(stdout).toContain('Library Pega_DXIL/0.0.1-dev has been created!');
85
+ expect(stdout).toContain('Library Pega_DXIL/0.0.1 has been created!');
86
86
 
87
87
  const doesExist = fs.existsSync(path.resolve('../../..', compConf));
88
88
 
@@ -186,9 +186,9 @@ describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} -
186
186
  // }
187
187
  }, 10000);
188
188
 
189
- it(`npm run buildLib (internal) - ${isLibraryBased}`, async() => {
189
+ it(`npm run buildLib (internal) - ${isLIbraryBasedC}`, async() => {
190
190
 
191
- const script = `npm run _internal-buildLibrary 0.0.1 Y --prefix ../../..`;
191
+ const script = `npm run _internal-buildLibrary 0.0.1 N --prefix ../../..`;
192
192
  const { stdout, stderr } = await exec(script);
193
193
 
194
194
  expect(stdout).not.toContain('JWT token has expired, please reauthenticate.');
@@ -199,7 +199,7 @@ describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} -
199
199
  expect(stdout).toContain('Building Library...');
200
200
  expect(stdout).toContain('Compile check...');
201
201
 
202
- expect(stdout).toContain('Webpacked library Pega_DXIL:0.0.1-dev successfully!!');
202
+ expect(stdout).toContain('Webpacked library Pega_DXIL:0.0.1 successfully!!');
203
203
  expect(stdout).toContain('== Creating manifest for the library version - completed ==');
204
204
 
205
205
 
@@ -207,29 +207,29 @@ describe(`createLib create buildLib deleteLib deletePublishedLib: ${serverDir} -
207
207
  }, 200000);
208
208
 
209
209
 
210
- it(`npm run listPublishedLib - ${isLibraryBased}`, async() => {
210
+ it(`npm run listPublishedLib - ${isLIbraryBasedC}`, async() => {
211
211
 
212
- const script = `npm run listPublishedLib Local Pega_DXIL 0.0.1-dev --prefix ../../..`;
212
+ const script = `npm run listPublishedLib Local Pega_DXIL 0.0.1 --prefix ../../..`;
213
213
  const { stdout, stderr } = await exec(script);
214
214
 
215
215
  expect(stdout).toContain('Pega_DXIL_MyTestText');
216
216
  expect(stdout).toContain('Pega_DXIL_MyTestPage');
217
217
  expect(stdout).toContain('Pega_DXIL_MyTestDetails');
218
218
 
219
- expect(stdout).toContain('0.0.1-dev');
219
+ expect(stdout).toContain('0.0.1');
220
220
 
221
221
 
222
222
  }, 30000);
223
223
 
224
- it(`npm run deleteLib - ${isLibraryBased}`, async() => {
224
+ it(`npm run deleteLib - ${isLIbraryBasedC}`, async() => {
225
225
 
226
- const script = `npm run deleteLib Pega_DXIL 0.0.1-dev Y --prefix ../../..`;
226
+ const script = `npm run deleteLib Pega_DXIL 0.0.1 Y --prefix ../../..`;
227
227
  const { stdout, stderr } = await exec(script);
228
228
  expect(stdout).toContain('Pega_DXIL is deleted from Local.');
229
229
 
230
230
  }, 30000);
231
231
 
232
- it(`npm run deletePublishedLib - ${isLibraryBased}`, async() => {
232
+ it(`npm run deletePublishedLib - ${isLIbraryBasedC}`, async() => {
233
233
 
234
234
  const script = `npm run deletePublishedLib Local ALL --prefix ../../..`;
235
235
  const { stdout, stderr } = await exec(script);