Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 15 additions & 12 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -1,29 +1,31 @@
#! groovy
library 'pipeline-library'
// TODO: Could we make this an array and test across multiple major versions
def nodeVersion = '8.9.1'
def nodeVersion = '8.16.0'

def unitTests(os, nodeVersion) {
return {
node(os) {
nodejs(nodeJSInstallationName: "node ${nodeVersion}") {
stage('Test') {
try {
nodejs(nodeJSInstallationName: "node ${nodeVersion}") {
timeout(15) {
unstash 'sources'
if (sh(returnStatus: true, script: 'which yarn') != 0) {
sh 'npm install -g yarn'
}
sh 'yarn install'
fingerprint 'package.json'
ensureYarn()
command 'yarn install' // runs bat on win, sh on unix/mac
try {
sh 'yarn run coverage'
} finally {
// record results even if tests/coverage 'fails'
junit 'junit.xml'
if (fileExists('coverage/cobertura-coverage.xml')) {
step([$class: 'CoberturaPublisher', autoUpdateHealth: false, autoUpdateStability: false, coberturaReportFile: 'coverage/cobertura-coverage.xml', failUnhealthy: false, failUnstable: false, maxNumberOfBuilds: 0, onlyStable: false, sourceEncoding: 'ASCII', zoomCoverageChart: false])
}
}
} // timeout
} // test
} // nodejs
} // nodejs
} finally {
deleteDir() // wipe the workspace no matter what
}
} // node
}
}
Expand All @@ -47,6 +49,7 @@ timestamps {
isMaster = env.BRANCH_NAME.equals('master')
packageVersion = jsonParse(readFile('package.json'))['version']
currentBuild.displayName = "#${packageVersion}-${currentBuild.number}"
fingerprint 'package.json'
stash allowEmpty: true, name: 'sources', useDefaultExcludes: false
}
}
Expand All @@ -55,7 +58,7 @@ timestamps {
parallel(
'OSX unit tests': unitTests('osx', nodeVersion),
failFast: false
)
)
} // Test

} // timestamps
} // timestamps
2 changes: 1 addition & 1 deletion src/certs.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { run } from 'appcd-subprocess';
const BEGIN = '-----BEGIN CERTIFICATE-----';
const END = '-----END CERTIFICATE-----';
const wwdrName = 'Apple Worldwide Developer Relations Certification Authority';
const certRegExp = /^(?:(iOS Development|iPhone Developer)|((?:iOS|iPhone) Distribution)): (.+)$/;
const certRegExp = /^(?:((?:Apple|iOS) Development|iPhone Developer)|((?:Apple|iOS|iPhone) Distribution)): (.+)$/;

/**
* Detects the installed certs across all keychains, then sorts them into either an iOS Developer
Expand Down