Uploaded image for project: 'Data Management'
  1. Data Management
  2. DM-1407

Add return code for integration tests

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Resolution: Done
    • Fix Version/s: None
    • Component/s: Qserv
    • Labels:
      None

      Description

      Integration test have to returns non-zero when failing. This will ease use of CI or debugging tools (git bisect, buildbot).

        Attachments

          Issue Links

            Activity

            Hide
            jammes Fabrice Jammes added a comment -

            A git-bisect example script might be proposed in a future ticket:

            For example:

            killall mysqld mysql-proxy xrootd java python
            setup -k -r . &&
            rm -rf build lib proxy bin cfg  &&
            eupspkg -e PREFIX=$PWD install &&
            qserv-configure.py --all --force &&
            ~/qserv-run/2014_10.0/bin/qserv-start.sh &&
            qserv-test-integration.py &&
            ~/qserv-run/2014_10.0/bin/qserv-stop.sh

            Show
            jammes Fabrice Jammes added a comment - A git-bisect example script might be proposed in a future ticket: For example: killall mysqld mysql-proxy xrootd java python setup -k -r . && rm -rf build lib proxy bin cfg && eupspkg -e PREFIX=$PWD install && qserv-configure.py --all --force && ~ /qserv-run/2014_10 .0 /bin/qserv-start .sh && qserv- test -integration.py && ~ /qserv-run/2014_10 .0 /bin/qserv-stop .sh
            Hide
            salnikov Andy Salnikov added a comment -

            Hi Fabrice,

            did you push anything into origin for review, or what am I supposed to review?

            Andy

            Show
            salnikov Andy Salnikov added a comment - Hi Fabrice, did you push anything into origin for review, or what am I supposed to review? Andy
            Hide
            jammes Fabrice Jammes added a comment -

            Hi Andy,

            Sorry for not specifying the repository to review. Ticket branch is here https://dev.lsstcorp.org/cgit/LSST/DMS/testdata/qserv_testdata.git/.

            Cheers,

            Fabrice

            Show
            jammes Fabrice Jammes added a comment - Hi Andy, Sorry for not specifying the repository to review. Ticket branch is here https://dev.lsstcorp.org/cgit/LSST/DMS/testdata/qserv_testdata.git/ . Cheers, Fabrice
            Hide
            salnikov Andy Salnikov added a comment -

            My bad, I forgot we have second repository which also has scripts now. Friday afternoon, my brains are not functioning well I'll try to review it today.

            Show
            salnikov Andy Salnikov added a comment - My bad, I forgot we have second repository which also has scripts now. Friday afternoon, my brains are not functioning well I'll try to review it today.
            Hide
            salnikov Andy Salnikov added a comment -

            It's small change and looks OK, couple of comments:

            • would it make sense to do the same for other test scripts (qserv-check-integration.py, qserv-testunit.py)?
            • I'm a bit worried about calling sys.exit() with boolean expression as an argument. Python bool is a subclass of int but sys.exit() documentation does not say anything about subclasses, it only mentions int. Being paranoid I'd add explicit conversion to int: sys.exit(int(expression)).
            Show
            salnikov Andy Salnikov added a comment - It's small change and looks OK, couple of comments: would it make sense to do the same for other test scripts ( qserv-check-integration.py , qserv-testunit.py )? I'm a bit worried about calling sys.exit() with boolean expression as an argument. Python bool is a subclass of int but sys.exit() documentation does not say anything about subclasses, it only mentions int. Being paranoid I'd add explicit conversion to int: sys.exit(int(expression)) .
            Hide
            jammes Fabrice Jammes added a comment -

            Thanks Andy,

            • yes, it makes sense.
            • ok, I'll do it, what a pity python isn't a bit more typed.
            Show
            jammes Fabrice Jammes added a comment - Thanks Andy, yes, it makes sense. ok, I'll do it, what a pity python isn't a bit more typed.

              People

              Assignee:
              jammes Fabrice Jammes
              Reporter:
              jammes Fabrice Jammes
              Reviewers:
              Andy Salnikov
              Watchers:
              Andy Salnikov, Fabrice Jammes, Jacek Becla
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Jenkins

                  No builds found.