Mercurial > kallithea
comparison Jenkinsfile @ 6551:bc1b11a5d548
jenkinsfile: catch the correct exception if jenkins plugin is not available
author | domruf <dominikruf@gmail.com> |
---|---|
date | Wed, 15 Mar 2017 12:36:43 +0100 |
parents | ad275fcc5a90 |
children | 15a12f2a47b4 |
comparison
equal
deleted
inserted
replaced
6550:ad275fcc5a90 | 6551:bc1b11a5d548 |
---|---|
53 pylint -j 0 --disable=C -f parseable kallithea > pylint.out | 53 pylint -j 0 --disable=C -f parseable kallithea > pylint.out |
54 """, returnStatus: true | 54 """, returnStatus: true |
55 archiveArtifacts 'pylint.out' | 55 archiveArtifacts 'pylint.out' |
56 try { | 56 try { |
57 step([$class: 'WarningsPublisher', canComputeNew: false, canResolveRelativePaths: false, defaultEncoding: '', excludePattern: '', healthy: '', includePattern: '', messagesPattern: '', parserConfigurations: [[parserName: 'PyLint', pattern: 'pylint.out']], unHealthy: '']) | 57 step([$class: 'WarningsPublisher', canComputeNew: false, canResolveRelativePaths: false, defaultEncoding: '', excludePattern: '', healthy: '', includePattern: '', messagesPattern: '', parserConfigurations: [[parserName: 'PyLint', pattern: 'pylint.out']], unHealthy: '']) |
58 } catch (UnsupportedOperationException exc) { | 58 } catch (java.lang.IllegalArgumentException exc) { |
59 echo "You need to install the 'Warnings Plug-in' to display the pylint report." | 59 echo "You need to install the 'Warnings Plug-in' to display the pylint report." |
60 currentBuild.result = 'UNSTABLE' | 60 currentBuild.result = 'UNSTABLE' |
61 echo "Caught: ${exc}" | 61 echo "Caught: ${exc}" |
62 } | 62 } |
63 } | 63 } |
77 sh 'sed --in-place "s/\\(classname=[\'\\"]\\)/\\1SQLITE./g" pytest_sqlite.xml' | 77 sh 'sed --in-place "s/\\(classname=[\'\\"]\\)/\\1SQLITE./g" pytest_sqlite.xml' |
78 archiveArtifacts 'pytest_sqlite.xml' | 78 archiveArtifacts 'pytest_sqlite.xml' |
79 junit 'pytest_sqlite.xml' | 79 junit 'pytest_sqlite.xml' |
80 try { | 80 try { |
81 step([$class: 'CoberturaPublisher', autoUpdateHealth: false, autoUpdateStability: false, coberturaReportFile: 'coverage.xml', failNoReports: false, failUnhealthy: false, failUnstable: false, maxNumberOfBuilds: 0, onlyStable: false, zoomCoverageChart: false]) | 81 step([$class: 'CoberturaPublisher', autoUpdateHealth: false, autoUpdateStability: false, coberturaReportFile: 'coverage.xml', failNoReports: false, failUnhealthy: false, failUnstable: false, maxNumberOfBuilds: 0, onlyStable: false, zoomCoverageChart: false]) |
82 } catch (UnsupportedOperationException exc) { | 82 } catch (java.lang.IllegalArgumentException exc) { |
83 echo "You need to install the pipeline compatible 'CoberturaPublisher Plug-in' to display the coverage report." | 83 echo "You need to install the pipeline compatible 'CoberturaPublisher Plug-in' to display the coverage report." |
84 currentBuild.result = 'UNSTABLE' | 84 currentBuild.result = 'UNSTABLE' |
85 echo "Caught: ${exc}" | 85 echo "Caught: ${exc}" |
86 } | 86 } |
87 } | 87 } |