From 01957741c8bb74cec6e72c734ba0b8589efa1f72 Mon Sep 17 00:00:00 2001 From: Matt Rendina Date: Mon, 15 Apr 2019 10:18:59 -0400 Subject: Add tests dir; try out inclusion into jenkinsfile Cleanup jenkinsfile. Add hook instalation script Rename jenkinsfile.test Update hook to use renamed Jenkinsfile --- tests/access_env_var.sh | 4 ++++ tests/setup.cfg | 3 +++ tests/test_25pass.py | 11 +++++++++++ tests/test_75pass.py | 11 +++++++++++ tests/test_alwaysfail.py | 2 ++ tests/test_alwayspass.py | 3 +++ 6 files changed, 34 insertions(+) create mode 100755 tests/access_env_var.sh create mode 100644 tests/setup.cfg create mode 100644 tests/test_25pass.py create mode 100644 tests/test_75pass.py create mode 100644 tests/test_alwaysfail.py create mode 100644 tests/test_alwayspass.py (limited to 'tests') diff --git a/tests/access_env_var.sh b/tests/access_env_var.sh new file mode 100755 index 0000000..b7a5b3f --- /dev/null +++ b/tests/access_env_var.sh @@ -0,0 +1,4 @@ +#!/usr/bin/env bash + +echo "This is the value of SECRET_VALUE" +echo "${SECRET_VALUE}" diff --git a/tests/setup.cfg b/tests/setup.cfg new file mode 100644 index 0000000..fed90fd --- /dev/null +++ b/tests/setup.cfg @@ -0,0 +1,3 @@ +[tool:pytest] +junit_family=xunit2 +results_root = datb-generic diff --git a/tests/test_25pass.py b/tests/test_25pass.py new file mode 100644 index 0000000..a18bb9c --- /dev/null +++ b/tests/test_25pass.py @@ -0,0 +1,11 @@ +def test_25_1of4(): + assert 1==1 + +def test_25_2of4(): + assert 1==2 + +def test_25_3of4(): + assert 1==3 + +def test_25_4of4(): + assert 1==4 diff --git a/tests/test_75pass.py b/tests/test_75pass.py new file mode 100644 index 0000000..88028a7 --- /dev/null +++ b/tests/test_75pass.py @@ -0,0 +1,11 @@ +def test_75_1of4(): + assert 1==1 + +def test_75_2of4(): + assert 1==1 + +def test_75_3of4(): + assert 1==1 + +def test_75_4of4(): + assert 1==4 diff --git a/tests/test_alwaysfail.py b/tests/test_alwaysfail.py new file mode 100644 index 0000000..c3c2558 --- /dev/null +++ b/tests/test_alwaysfail.py @@ -0,0 +1,2 @@ +def test_alwaysfail(): + assert 1==2 diff --git a/tests/test_alwayspass.py b/tests/test_alwayspass.py new file mode 100644 index 0000000..7e84d20 --- /dev/null +++ b/tests/test_alwayspass.py @@ -0,0 +1,3 @@ +def test_alwayspass(): + assert 1==1 + -- cgit