From e475b83c1f711e77814d68f933ff2d661102806a Mon Sep 17 00:00:00 2001 From: RHE Date: Wed, 17 Jan 2018 14:35:01 +0100 Subject: jenkins conf Change-Id: Ide859a78b8b4f05008106d9aca8f84eaeb0f538b Signed-off-by: RHE --- Jenkinsfile | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 Jenkinsfile (limited to 'Jenkinsfile') diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 00000000..42756ece --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,23 @@ +properties([ + pipelineTriggers([cron('H * * * *')]) +]) +node { + checkout scm + def packages = ["python_moonutilities","python_moondb","python_moonclient"] + def subtests = [:] + for (x in packages) { + def pkg = x + subtests[pkg] = { + withDockerContainer('wukongsun/moon_python_unit_test') { + stage("Install prerequisites for package ${pkg}") { + sh("pip install pytest requests_mock requests --upgrade") + sh("cd ${pkg} && pip install -r tests/unit_python/requirements.txt && pip install .") + } + stage("Unit test for package ${pkg}") { + sh "cd ${pkg}/tests/unit_python && pytest ." + } + } + } + } + parallel subtests +} \ No newline at end of file -- cgit 1.2.3-korg