File tree Expand file tree Collapse file tree 3 files changed +15
-3
lines changed Expand file tree Collapse file tree 3 files changed +15
-3
lines changed Original file line number Diff line number Diff line change @@ -57,6 +57,16 @@ def runAuditReport() {
5757 '''
5858}
5959
60+ // For now, only failing on errors. See eslint.config.js for the lint configuration.
61+ def runLint () {
62+ sh label : ' run-lint' , script : '''
63+ export PATH=${NODE_HOME_DIR}/bin:$PATH
64+ cd node-client-api
65+ npm ci
66+ npm run lint -- --quiet
67+ '''
68+ }
69+
6070def runE2ETests () {
6171 sh label : ' run-e2e-tests' , script : '''
6272 export JAVA_HOME=$JAVA_HOME_DIR
@@ -123,6 +133,7 @@ pipeline {
123133 agent { label ' nodeclientpool' }
124134 steps {
125135 runAuditReport()
136+ runLint()
126137 runDockerCompose(' ml-docker-db-dev-tierpoint.bed-artifactory.bedford.progress.com/marklogic/marklogic-server-ubi:latest-12' )
127138 runTests()
128139 runE2ETests()
Original file line number Diff line number Diff line change @@ -30,14 +30,14 @@ module.exports = [
3030 "semi" : [ "error" , "always" ] ,
3131
3232 // Modern best practices
33- "eqeqeq" : "error" ,
33+ "eqeqeq" : "warn" , // TODO: Fix == vs === issues in follow-up PR
3434 "curly" : [ "error" , "all" ] , // Require braces for all control structures
35- "no-unused-vars" : "error" ,
35+ "no-unused-vars" : "warn" , // TODO: Fix unused variables in follow-up PR
3636 "no-undef" : "error" ,
3737
3838 // ES6+ modernization - GO TIME! 🚀
3939 "prefer-const" : "error" , // Use const for variables never reassigned
40- "no-var" : "error " , // Disallow var, use let/const instead
40+ "no-var" : "warn " , // TODO: Fix remaining var declarations in follow-up PR
4141
4242 // Spacing rules (disabled for initial setup - TODO: Fix in separate PR)
4343 "arrow-spacing" : "off" ,
Original file line number Diff line number Diff line change 88 "main" : " ./lib/marklogic.js" ,
99 "scripts" : {
1010 "doc" : " gulp doc" ,
11+ "lint" : " gulp lint" ,
1112 "test:setup" : " node etc/test-setup.js" ,
1213 "test:teardown" : " node etc/test-teardown.js" ,
1314 "test" : " gulp test"
You can’t perform that action at this time.
0 commit comments