Opened 13 years ago

Closed 12 years ago

#355 closed task (fixed)

skip test (rather than avoiding them)

Reported by: Peter Johansson Owned by: Peter Johansson
Priority: trivial Milestone: svndigest 0.7
Component: build Version: trunk
Keywords: Cc:

Description (last modified by Peter Johansson)

related to ticket:362

For example tests that need the test repository should not be avoided by AM_CONITIONAL, but instead they should return 77 (which signals SKIP) to make check

Change History (8)

comment:1 Changed 12 years ago by Peter Johansson

Description: modified (diff)

Given ticket:362, it is clear that the check if we HAVE_SVN_WC is not the most relevant way to decide if we should skip some tests. Read svn export. We should check if the repository is available instead.

comment:2 Changed 12 years ago by Jari Häkkinen

My understanding of svn export is that the directory structure is exported without svn meta information. If we work in a svn export'ed environemnt we should skip tests? Also, what is the difference with 'HAVE_SVN_WC' and that repository is available. I thought these say the same thing.

comment:3 in reply to:  2 Changed 12 years ago by Peter Johansson

Replying to jari:

My understanding of svn export is that the directory structure is exported without svn meta information.

Exactly.

If we work in a svn export'ed environemnt we should skip tests?

No what I suggest is that tests should not be skipped in an svn export'ed environment.

Also, what is the difference with 'HAVE_SVN_WC' and that repository is available. I thought these say the same thing.

At time being HAVE_SVN_WC is set to false if svnversion returns 'exported', in other words, if svn meta information is not available. So HAVE_SVN_WC means we have svn meta information, which we don't have when building from a dist or from an 'svn export'. OTOH, if you export from the repository you will get everything checked in, including the test repository. And if the repository is there, we should use it in tests.

Of mote, HAVE_SVN_WC is not ill defined because the inital purpose of it was to decide whether we should rebuild lib/svnversion_info.cc (which issues svn info). The mistake was to use HAVE_SVN_WC in test/Makefile.am as having svn meta info and having access to the test repository is not the same thing.

comment:4 Changed 12 years ago by Peter Johansson

(In [730]) Check if we HAVE_SVN_WC by looking for .svn directory rather than relying on svnversion output.

Check if we HAVE_TEST_REPO by looking for test/repo. This variable is used to activate test that need the test repo, i.e., they are activated also in svn export mode.

refs #362 and #355

comment:5 Changed 12 years ago by Peter Johansson

(In [734]) check_repo_status.sh needs svn meta information - actually the entire purpose of the check is gone when building from an svn export - refs #355

comment:6 Changed 12 years ago by Peter Johansson

Milestone: svndigest 0.x+svndigest 0.7
Status: newassigned

comment:7 Changed 12 years ago by Peter Johansson

(In [738]) refs #355 - check_repo_status.sh is now skipped when not appropriate

comment:8 Changed 12 years ago by Peter Johansson

Resolution: fixed
Status: assignedclosed

(In [744]) fixes #355 - skipping tests. Added some support in test::Suite to handle the test repo. There is a bool in constructor telling if the tests needs the test repo. test::Suite uses a new script svn_update.sh to check out and update the test repo. This script is used in test_repo.sh as well.

Note: See TracTickets for help on using tickets.