]> Frank Brehm's Git Trees - profitbricks/jenkins-build-scripts.git/commitdiff
remove traces of testlink, as its not used anymore
authorHolger Levsen <holger@layer-acht.org>
Fri, 13 Sep 2013 10:18:02 +0000 (12:18 +0200)
committerHolger Levsen <holger@layer-acht.org>
Fri, 13 Sep 2013 10:18:02 +0000 (12:18 +0200)
liveboot_build.sh
liveboot_gw_autotest.sh
liveboot_testlink_update_testcase.py [deleted file]

index 28591fa0c0018ac6389de046d021242dcb3c808b..871a7f27e7356440b5fe04a743fa5fa94bea678b 100755 (executable)
@@ -7,7 +7,6 @@ set_failure() {
        BUILD_END=$(date +%s)
        $SCRIPTSDIR/liveboot2db.py $JOB_NAME $BUILD_NUMBER $REQUEST_ID $BUILD_START $BUILD_END "failed"
     build_name=$(basename $(readlink -f /srv/build/liveboot/builds/last))
-    $SCRIPTSDIR/liveboot_testlink_update_testcase.py "$build_name" "failed"
        # cleanup mount points
        cd /var/cache/pbuilder/build
        echo "My PID: $$"
@@ -64,12 +63,6 @@ echo "sudo pbuilder --execute --bindmounts /srv/build/ -- $BUILD_SCRIPT" > ${BUI
 bash -x ${BUILD_SCRIPT}_sudo
 rm $BUILD_SCRIPT ${BUILD_SCRIPT}_sudo
 
-#
-# report build status to testlink testcase
-#
-build_name=$(basename $(readlink -f /srv/build/liveboot/builds/last))
-$SCRIPTSDIR/liveboot_testlink_update_testcase.py "$build_name" "successful"
-
 #
 # add liveboot build result to cidb
 #
index 05846327161c6196dc2a12782617b6da5b9ff07f..1aeacdbc64384eaa0ce79cba68b542d24f512a85 100755 (executable)
@@ -18,7 +18,6 @@ PSERVER=pserver1301
 
 echo "LIVEBOOT_BUILD_NUMBER: ${LIVEBOOT_BUILD_NUMBER}"
 echo "AUTOTEST_BRANCH: ${AUTOTEST_BRANCH}"
-echo "REPORT_TO_TESTLINK: ${REPORT_TO_TESTLINK}"
 echo "AUTOTEST_CONFIG: ${AUTOTEST_CONFIG}"
 #
 # prepare ssh
@@ -69,18 +68,11 @@ ssh -t $CORE_ROUTER "cd /opt/autotest ; git checkout ${AUTOTEST_BRANCH}"
 #
 # run autotests
 #
-# call autotest suite w/ testlink connector info
+# call autotest suite 
 ssh -t -A $CORE_ROUTER "cd /opt/autotest ; ./compile.sh"
+ssh -t -A $CORE_ROUTER "cd /opt/autotest ;  java -ea -jar dist/lib/AutoTest.jar --tracepjds --config=${AUTOTEST_CONFIG}"
 
-if [ ${REPORT_TO_TESTLINK} == "true" ]; then
-        echo "Report Results to TestLink..."
-       ssh -t -A $CORE_ROUTER "cd /opt/autotest ;  java -ea -jar dist/lib/AutoTest.jar --testlink='Profitbricks,R&I Liveboot Approval Autotest,liveboot-${LIVEBOOT_BUILD_NUMBER},R&I HW Test Bed'"
-else
-       ssh -t -A $CORE_ROUTER "cd /opt/autotest ;  java -ea -jar dist/lib/AutoTest.jar --tracepjds --config=${AUTOTEST_CONFIG}"
-fi
-
-
-# no testlink support in vcb tests yet
+# run vcb tests
 ssh -t -A $CORE_ROUTER "cd /opt/autotest ; ./run-compile.sh --vcb=true --tracepjds"
 
 #
diff --git a/liveboot_testlink_update_testcase.py b/liveboot_testlink_update_testcase.py
deleted file mode 100755 (executable)
index 24d38a9..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-#!/usr/bin/env python
-
-""" The build.sh liveboot script creates a new Testlink Project for every
-Liveboot image that is build. This script reports if a liveboot build was
-successful or failed to the testlink testcase 'Liveboot Image Build' """
-
-import logging
-import sys
-import xmlrpclib
-
-
-TESTLINK_API_URL = "http://testlink/lib/api/xmlrpc.php"
-TESTLINK_DEV_KEY = "6805a288081cf7480d391533b354cb7c"
-TESTLINK_IMAGE_BUILD_TESTCASE_ID = "PB-601"
-TESTLINK_PLATFORM = "R&I HW Test Bed"
-logger = logging.getLogger(__name__)
-
-
-class TestlinkAPIClient:
-    def __init__(self):
-        self.server = xmlrpclib.Server(TESTLINK_API_URL)
-        self.devKey = TESTLINK_DEV_KEY
-
-    def getTestPlanId(self, name):
-        data = {"devKey": self.devKey, "testprojectname": "Profitbricks",
-                "testplanname": name}
-        return self.server.tl.getTestPlanByName(data)
-
-    def reportTestCaseResult(self, testcaseexternalid, testplanid, buildname,
-                             status, notes):
-        # valid status values:
-        # 'p' = passed
-        # 'b' = blocked
-        # 'f' = failed
-        data = {"devKey": self.devKey, "testcaseexternalid":
-                testcaseexternalid, "testplanid": testplanid, "buildname":
-                buildname, "platformname": TESTLINK_PLATFORM, "status": status}
-        return self.server.tl.reportTCResult(data)
-
-
-def update_testlink_testcase(buildname, status, notes=""):
-    logger.info("Updating testlink testcase for build %s, testcase result: %s"
-            % (buildname, status))
-# set testcaseexternalid, ignore testcaseid
-    t = TestlinkAPIClient()
-    testplan_id = t.getTestPlanId("R&I Liveboot Approval Autotest")[0]["id"]
-    res = t.reportTestCaseResult(TESTLINK_IMAGE_BUILD_TESTCASE_ID, testplan_id,
-            buildname, status, notes)
-    logger.info("Testlink server returned: %s" % res)
-
-
-if __name__ == "__main__":
-    logging.basicConfig(level=logging.DEBUG)
-
-    if len(sys.argv) < 3:
-        print("usage: %s BUILDNAME (failed|successful)" % sys.argv[0])
-        sys.exit(1)
-    if sys.argv[2] == "successful":
-        update_testlink_testcase(sys.argv[1], "p")
-    elif sys.argv[2] == "failed":
-        update_testlink_testcase(sys.argv[1], "f")