Skip to content

Commit

Permalink
CIV-5790 change pipeline type to nodejs (#1706)
Browse files Browse the repository at this point in the history
* initial change to pipeline type

* revert setup step

* revert previous commit

* add unit tests

* change yarn:test command

* revert unit tests

* add dummy unit test

* try running all FTs

* try running all FTs

* try to fix lint

* add test coverage

* add sonar properties files

* revert some changes to Jenkinsfile_CNP

* add setup step

* add highleveldatasetup to package.json

* run only functional tests

* fix path

* temporarily skip functional tests

* revert previous commit

* use gradle task instead

* fix quotes

* try running script intead

* fix command

* fix permissions

* temporarily disable some tests

* try using gradle instead

* try using gradle instead

* fix script (test)

* fix permissions

* update nightly config

* revert accidental commit

* try updating build.gradle

* fix path

* test command

* fix permissions

* fix vars

* test with bad config

* test with bad config

* add definition unit tests

* fix lint

* add sonar exclusions

* add sonar exclusions

* add sonar exclusions

* update sonar exclusions

* update sonar exclusions

* update sonar exclusions

* update sonar exclusions

* update sonar exclusions

* update sonar exclusions

* add access profiles config test

* remove some HighLevelDataSetupApp changes

* remove some HighLevelDataSetupApp changes

* rename file

* run tests for different env configs

* lint fixes

* fix broken exclusions

* update exclusions

* restore shouldTolerateDataSetupFailure to HighLevelDataSetupApp

* add comment to dataProvider

* delete suppressions.xml

* add more info to assertion error

* delete suppressions.xml

* removing empty files, moving GENERATE_RESPONSE_SEALED to base file (leaving CUI version in CUI non prod). Rejigging dataProvider exclusions

* user role in case field moved

* additional checks added

* exclusion added

* exclusion error fixed

* unnecessary check removed

* test command changed

* unnecessary if statement removed

* unnecessary suppressions.xml removed

* restore CUI file

---------

Co-authored-by: mounikahmcts <[email protected]>
Co-authored-by: HarryH <[email protected]>
Co-authored-by: Harry H <[email protected]>
Co-authored-by: Maciej Modzelewski <[email protected]>
Co-authored-by: Maciej Modzelewski <[email protected]>
Co-authored-by: Filippo Possenti <[email protected]>
  • Loading branch information
7 people authored Jan 31, 2023
1 parent 29f2ba5 commit 92078bf
Show file tree
Hide file tree
Showing 55 changed files with 1,252 additions and 1,183 deletions.
4 changes: 3 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ module.exports = {
'commonjs': true,
'es2020': true,
'codeceptjs/codeceptjs': true,
'node': true
'node': true,
'mocha': true,
'jest': true
},
'extends': 'eslint:recommended',
'parserOptions': {
Expand Down
5 changes: 4 additions & 1 deletion Jenkinsfile_CNP
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,13 @@
@Library("Infrastructure")
import uk.gov.hmcts.contino.GithubAPI

def type = "java"
def type = "nodejs"
def product = "civil"
def component = "ccd"
def camundaBranch = "master"

def yarnBuilder = new uk.gov.hmcts.contino.YarnBuilder(this)

static Map<String, Object> secret(String secretName, String envVariable) {
[$class : 'AzureKeyVaultSecret',
secretType : 'Secret',
Expand Down Expand Up @@ -131,6 +133,7 @@ withPipeline(type, product, component) {
}

before('highleveldatasetup') {
yarnBuilder.yarn('setup')
archiveCoreCaseDataDefinitions()
}

Expand Down
2 changes: 1 addition & 1 deletion Jenkinsfile_nightly
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ properties([

@Library("Infrastructure")

def type = "java"
def type = "nodejs"
def product = "civil"
def component = "ccd"

Expand Down
5 changes: 4 additions & 1 deletion bin/build-release-ccd-definition.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,21 @@ set -eu
environment=${1:-prod}
excludeNonProdFiles=${2:-true}

# if any exclusions are updated here, please also update the exclusions map in e2e/tests/unit/utils/dataProvider.js
if [ ${environment} == preview ]; then
excludedFilenamePatterns="-e *-prod.json,*HNL-nonprod.json,*CUI.json,*CUI-nonprod.json,*-GAR2GAspec-nonprod.json"
#for testing HNL uplifting, comment the above line and uncomment below
#excludedFilenamePatterns="-e *-prod.json,*CUI.json,*CUI-nonprod.json,*-base-nonprod.json"
#excludedFilenamePatterns="-e *-prod.json,*-base-nonprod.json,*CUI.json,*CUI-nonprod.json"
#for testing ga enhancements please remove *-GAR2GAspec-nonprod.json which are not required for release 1
elif [ ${environment} == demo ]; then
excludedFilenamePatterns="-e UserProfile.json,*-prod.json,*HNL-nonprod.json,*-GAR2GAspec-nonprod.json,*CUI-nonprod.json"
elif [ ${environment} == local ]; then
# upload doesn't currently work with this command due to SDO and SDO-HNL files
excludedFilenamePatterns="-e *-prod.json"
elif [ ${excludeNonProdFiles} == true ]; then
excludedFilenamePatterns="-e UserProfile.json,*-nonprod.json,*-COS-nonprod.json,*GAspec.json,*-GAR2GAspec-nonprod.json,*DJ.json,*DJspec.json,*DJ-SDO-nonprod.json,*DJ-nonprod.json,*CUI.json,*CUI-nonprod.json,*-GAR3CP-nonprod.json"
else
#default
excludedFilenamePatterns="-e UserProfile.json,*GAspec.json,*-GAR2GAspec-nonprod.json,*-prod.json,*DJ.json,*DJspec.json,*-HNL-nonprod.json,*CUI.json,*CUI-nonprod.json,*-GAR3CP-nonprod.json"
fi

Expand Down
Loading

0 comments on commit 92078bf

Please sign in to comment.