@zohodesk/testinglibrary 0.1.8-eslint-0 → 0.1.8-eslint-2
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/bin/cli.js
CHANGED
|
File without changes
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.sonarQubeIntegrateAnalysis = sonarQubeIntegrateAnalysis;
|
|
8
|
+
var _sonarqubeScanner = _interopRequireDefault(require("sonarqube-scanner"));
|
|
9
|
+
var _readConfigFile = require("../core/playwright/readConfigFile");
|
|
10
|
+
var _path = _interopRequireDefault(require("path"));
|
|
11
|
+
const postCallBack = () => process.exit();
|
|
12
|
+
const serverHostUrl = 'https://serverlinter-np.zohodesk.csez.zohocorpin.com';
|
|
13
|
+
const options = {
|
|
14
|
+
'sonar.projectName': 'UAT_Testing',
|
|
15
|
+
'sonar.login': "developer",
|
|
16
|
+
'sonar.password': "developer",
|
|
17
|
+
'sonar.sources': '',
|
|
18
|
+
'sonar.tests': `${_path.default.resolve(process.cwd(), 'uat', 'modules')}`,
|
|
19
|
+
'sonar.language': 'js',
|
|
20
|
+
'sonar.eslint.reportPaths': `${_path.default.resolve(process.cwd(), 'uat', 'eslint-report', 'lintReport.json')}`
|
|
21
|
+
};
|
|
22
|
+
function sonarQubeIntegrateAnalysis() {
|
|
23
|
+
(0, _sonarqubeScanner.default)({
|
|
24
|
+
serverUrl: serverHostUrl,
|
|
25
|
+
options: options
|
|
26
|
+
}, postCallBack);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
// "use strict";
|
|
30
|
+
|
|
31
|
+
// Object.defineProperty(exports, "__esModule", {
|
|
32
|
+
// value: true
|
|
33
|
+
// });
|
|
34
|
+
// exports.sonarScannerAnalysis = sonarScannerAnalysis;
|
|
35
|
+
// const scanner = require('sonarqube-scanner');
|
|
36
|
+
// const {
|
|
37
|
+
// generateConfigFromFile
|
|
38
|
+
// } = require('..');
|
|
39
|
+
// const postCallBack = () => process.exit();
|
|
40
|
+
// const serverHostUrl = 'https://serverlinter-np.zohodesk.csez.zohocorpin.com';
|
|
41
|
+
// const options = {
|
|
42
|
+
// 'sonar.projectName': 'UAT_Testing',
|
|
43
|
+
// 'sonar.login': "developer",
|
|
44
|
+
// 'sonar.password': "developer",
|
|
45
|
+
// 'sonar.sources': '',
|
|
46
|
+
// 'sonar.tests': `${path.resolve(process.cwd(), 'uat', 'modules')}`,
|
|
47
|
+
// 'sonar.language': 'js',
|
|
48
|
+
// 'sonar.eslint.reportPaths': `${path.resolve(process.cwd(), 'uat', 'eslint-report', 'lintReport.json')}`
|
|
49
|
+
// };
|
|
50
|
+
// function sonarScannerAnalysis() {
|
|
51
|
+
// scanner({
|
|
52
|
+
// serverHostUrl,
|
|
53
|
+
// options
|
|
54
|
+
// }, postCallBack);
|
|
55
|
+
// }
|
|
56
|
+
|
|
57
|
+
// scanner({
|
|
58
|
+
// serverUrl:'https://serverlinter-np.zohodesk.csez.zohocorpin.com/',
|
|
59
|
+
// options: {
|
|
60
|
+
// 'sonar.projectName': 'UAT_Testing',
|
|
61
|
+
// 'sonar.login':"developer",
|
|
62
|
+
// 'sonar.password':"developer",
|
|
63
|
+
// 'sonar.sources':'',
|
|
64
|
+
// 'sonar.tests':`${path.resolve(process.cwd(),'uat','modules')}`,
|
|
65
|
+
// 'sonar.language':'js',
|
|
66
|
+
// 'sonar.eslint.reportPaths':`${path.resolve(process.cwd(),'result.json')}`
|
|
67
|
+
// }
|
|
68
|
+
// },() => process.exit())
|
package/build/lib/cli.js
CHANGED
|
@@ -9,7 +9,7 @@ var _setupProject = _interopRequireDefault(require("../setup-folder-structure/se
|
|
|
9
9
|
var _parser = require("../parser/parser");
|
|
10
10
|
var _clearCaches = _interopRequireDefault(require("../core/playwright/clear-caches"));
|
|
11
11
|
var _helper = _interopRequireDefault(require("../setup-folder-structure/helper"));
|
|
12
|
-
var
|
|
12
|
+
var _reportConfigSonarQube = require("../integrate-dependencies/reportConfigSonarQube");
|
|
13
13
|
// import createJestRunner from '../core/jest/runner/jest-runner';
|
|
14
14
|
|
|
15
15
|
const [,, option, ...otherOptions] = process.argv;
|
|
@@ -57,8 +57,8 @@ switch (option) {
|
|
|
57
57
|
}
|
|
58
58
|
case 'eslint':
|
|
59
59
|
{
|
|
60
|
-
_logger.Logger.log(_logger.Logger.SUCCESS_TYPE, 'Eslint Report
|
|
61
|
-
(0,
|
|
60
|
+
_logger.Logger.log(_logger.Logger.SUCCESS_TYPE, 'Eslint Report Intergrate To SonarQube ....');
|
|
61
|
+
(0, _reportConfigSonarQube.sonarQubeIntegrateAnalysis)();
|
|
62
62
|
break;
|
|
63
63
|
}
|
|
64
64
|
case 'help':
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -5530,9 +5530,9 @@
|
|
|
5530
5530
|
}
|
|
5531
5531
|
},
|
|
5532
5532
|
"https-proxy-agent": {
|
|
5533
|
-
"version": "7.0.
|
|
5534
|
-
"resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.
|
|
5535
|
-
"integrity": "sha512-
|
|
5533
|
+
"version": "7.0.3",
|
|
5534
|
+
"resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.3.tgz",
|
|
5535
|
+
"integrity": "sha512-kCnwztfX0KZJSLOBrcL0emLeFako55NWMovvyPP2AjsghNk9RB1yjSI+jVumPHYZsNXegNoqupSW9IY3afSH8w==",
|
|
5536
5536
|
"dev": true,
|
|
5537
5537
|
"requires": {
|
|
5538
5538
|
"agent-base": "^7.0.2",
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zohodesk/testinglibrary",
|
|
3
|
-
"version": "0.1.8-eslint-
|
|
3
|
+
"version": "0.1.8-eslint-2",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./build/index.js",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"postinstall": "node bin/postinstall.js",
|
|
8
8
|
"test": "echo \"Error: no test specified\" && exit 1",
|
|
9
|
-
"clean": "
|
|
9
|
+
"clean": "rm -rf build && mkdir build",
|
|
10
10
|
"build-babel": "babel -d ./build ./src --copy-files",
|
|
11
11
|
"build": "npm run clean && npm run build-babel",
|
|
12
12
|
"prepare": "npm run build",
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.sonarScannerAnalysis = sonarScannerAnalysis;
|
|
7
|
-
const scanner = require('sonarqube-scanner');
|
|
8
|
-
const {
|
|
9
|
-
generateConfigFromFile
|
|
10
|
-
} = require('..');
|
|
11
|
-
const postCallBack = () => process.exit();
|
|
12
|
-
const serverHostUrl = 'https://serverlinter-np.zohodesk.csez.zohocorpin.com';
|
|
13
|
-
const options = {
|
|
14
|
-
'sonar.projectName': 'UAT_Testing',
|
|
15
|
-
'sonar.login': "developer",
|
|
16
|
-
'sonar.password': "developer",
|
|
17
|
-
'sonar.sources': '',
|
|
18
|
-
'sonar.tests': `${path.resolve(process.cwd(), 'uat', 'modules')}`,
|
|
19
|
-
'sonar.language': 'js',
|
|
20
|
-
'sonar.eslint.reportPaths': `${path.resolve(process.cwd(), 'uat', 'eslint-report', 'lintReport.json')}`
|
|
21
|
-
};
|
|
22
|
-
function sonarScannerAnalysis() {
|
|
23
|
-
scanner({
|
|
24
|
-
serverHostUrl,
|
|
25
|
-
options
|
|
26
|
-
}, postCallBack);
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
// scanner({
|
|
30
|
-
// serverUrl:'https://serverlinter-np.zohodesk.csez.zohocorpin.com/',
|
|
31
|
-
// options: {
|
|
32
|
-
// 'sonar.projectName': 'UAT_Testing',
|
|
33
|
-
// 'sonar.login':"developer",
|
|
34
|
-
// 'sonar.password':"developer",
|
|
35
|
-
// 'sonar.sources':'',
|
|
36
|
-
// 'sonar.tests':`${path.resolve(process.cwd(),'uat','modules')}`,
|
|
37
|
-
// 'sonar.language':'js',
|
|
38
|
-
// 'sonar.eslint.reportPaths':`${path.resolve(process.cwd(),'result.json')}`
|
|
39
|
-
// }
|
|
40
|
-
// },() => process.exit())
|