You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Brian Denny <br...@briandenny.net> on 2003/04/02 17:42:22 UTC
Re: svn commit: rev 5522 - in trunk/subversion: libsvn_client tests/clients/cmdline
On Wed, Apr 02, 2003 at 10:25:58AM -0600, kraai@tigris.org wrote:
> * subversion/tests/clients/cmdline/diff_tests.py
> (diff_nonextant_urls): New.
does this test pass for you? it fails for me.
> + if not re.match('svn: Filesystem has no item$', err_output[0]):
> + raise svntest.Failure
> +
> + diff_output, err_output = svntest.main.run_svn(None, 'diff', extant_url,
> + non_extant_url)
> + if not re.match('svn: Filesystem has no item$', err_output[0]):
> + raise svntest.Failure
here is the output i get when i run the test. it looks like svn diff
*is* erroring against the non-existant URL, but with a different error
string than what the test is checking for.
subversion/libsvn_ra_local/ra_plugin.c:249: (apr_err=180000)
svn: Couldn't find a repository.
svn: Unable to open an ra_local session to URL
subversion/libsvn_ra_local/split_url.c:153: (apr_err=180000)
svn: svn_ra_local__split_URL: Unable to find valid repository
(file:///usr/local/src/subversion/subversion/tests/clients/cmdline/repositories/diff_tests-12/A/does_not_exist)
FAIL: diff_tests.py 12: svn diff errors against a non-existant URL
-brian
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: svn commit: rev 5522 - in trunk/subversion: libsvn_client tests/clients/cmdline
Posted by Michael Wood <mw...@its.uct.ac.za>.
On Thu, Apr 03, 2003 at 04:54:37PM +0200, Robert Pluim wrote:
> Michael Wood writes:
> > On Thu, Apr 03, 2003 at 03:24:17PM +0200, Robert Pluim wrote:
> > > I thought the same initially, then wondered if that took into account
> > > lf vs crlf issues, so I played it safe ;-) (I don't have a windows
> > > machine to test on).
> >
> > hmmm... I would have expected the line ending characters to have been
> > stripped already, but I haven't looked at the code.
> >
>
> If I replace the regexp with:
>
> if 'svn: Filesystem has no item\n' == line:
>
> the test continues to work. If I use
>
> if 'svn: Filesystem has no item' == line:
>
> it fails, so the line ending is still there, however I don't know if
> python represents line endings the same on different platforms.
No, I'm pretty sure it would be '...\r\n' on Windows. Maybe Branko's
suggestion of an abstraction would help if it stripped the eol
characters.
--
Michael Wood <mw...@its.uct.ac.za>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: svn commit: rev 5522 - in trunk/subversion: libsvn_client tests/clients/cmdline
Posted by Robert Pluim <rp...@bigfoot.com>.
Michael Wood writes:
> On Thu, Apr 03, 2003 at 03:24:17PM +0200, Robert Pluim wrote:
> > I thought the same initially, then wondered if that took into account
> > lf vs crlf issues, so I played it safe ;-) (I don't have a windows
> > machine to test on).
>
> hmmm... I would have expected the line ending characters to have been
> stripped already, but I haven't looked at the code.
>
If I replace the regexp with:
if 'svn: Filesystem has no item\n' == line:
the test continues to work. If I use
if 'svn: Filesystem has no item' == line:
it fails, so the line ending is still there, however I don't know if
python represents line endings the same on different platforms.
--
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: svn commit: rev 5522 - in trunk/subversion: libsvn_client tests/clients/cmdline
Posted by Michael Wood <mw...@its.uct.ac.za>.
On Thu, Apr 03, 2003 at 03:24:17PM +0200, Robert Pluim wrote:
> Michael Wood writes:
> > On Wed, Apr 02, 2003 at 09:42:22AM -0800, Brian Denny wrote:
> > > On Wed, Apr 02, 2003 at 10:25:58AM -0600, kraai@tigris.org wrote:
> > > > * subversion/tests/clients/cmdline/diff_tests.py
> > > > (diff_nonextant_urls): New.
> > >
> > > does this test pass for you? it fails for me.
> > >
> > > > + if not re.match('svn: Filesystem has no item$', err_output[0]):
> >
> > No need for a regular expression. Rather use if err_output[0] == 'blah'
> >
>
> I thought the same initially, then wondered if that took into account
> lf vs crlf issues, so I played it safe ;-) (I don't have a windows
> machine to test on).
hmmm... I would have expected the line ending characters to have been
stripped already, but I haven't looked at the code.
--
Michael Wood <mw...@its.uct.ac.za>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: svn commit: rev 5522 - in trunk/subversion: libsvn_client tests/clients/cmdline
Posted by Robert Pluim <rp...@bigfoot.com>.
Michael Wood writes:
> On Wed, Apr 02, 2003 at 09:42:22AM -0800, Brian Denny wrote:
> > On Wed, Apr 02, 2003 at 10:25:58AM -0600, kraai@tigris.org wrote:
> > > * subversion/tests/clients/cmdline/diff_tests.py
> > > (diff_nonextant_urls): New.
> >
> > does this test pass for you? it fails for me.
> >
> > > + if not re.match('svn: Filesystem has no item$', err_output[0]):
>
> No need for a regular expression. Rather use if err_output[0] == 'blah'
>
I thought the same initially, then wondered if that took into account
lf vs crlf issues, so I played it safe ;-) (I don't have a windows
machine to test on).
--
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: svn commit: rev 5522 - in trunk/subversion: libsvn_client tests/clients/cmdline
Posted by Michael Wood <mw...@its.uct.ac.za>.
On Wed, Apr 02, 2003 at 09:42:22AM -0800, Brian Denny wrote:
> On Wed, Apr 02, 2003 at 10:25:58AM -0600, kraai@tigris.org wrote:
> > * subversion/tests/clients/cmdline/diff_tests.py
> > (diff_nonextant_urls): New.
>
> does this test pass for you? it fails for me.
>
> > + if not re.match('svn: Filesystem has no item$', err_output[0]):
No need for a regular expression. Rather use if err_output[0] == 'blah'
> > + raise svntest.Failure
> > +
> > + diff_output, err_output = svntest.main.run_svn(None, 'diff', extant_url,
> > + non_extant_url)
> > + if not re.match('svn: Filesystem has no item$', err_output[0]):
Same here.
--
Michael Wood <mw...@its.uct.ac.za>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: svn commit: rev 5522 - in trunk/subversion: libsvn_client tests/clients/cmdline
Posted by Matt Kraai <kr...@alumni.cmu.edu>.
On Wed, Apr 02, 2003 at 08:18:26PM +0200, Robert Pluim wrote:
> Robert Pluim writes:
> > Brian Denny writes:
> > > On Wed, Apr 02, 2003 at 10:25:58AM -0600, kraai@tigris.org wrote:
> > > > * subversion/tests/clients/cmdline/diff_tests.py
> > > > (diff_nonextant_urls): New.
> > >
> > > does this test pass for you? it fails for me.
> > >
> >
> > It passes for me. Let me investigate and get back to you.
>
> Repeat after me: when testing tests, start from a _completely clean_
> setup. I'd removed the sbox.build() earlier because I was under the
> mistaken impression that it only created the working copy, not the
> repository as well.
Thanks for the fix, applied. So much for your illustrious
reviewer.
Matt
--
It's most certainly GNU/Linux, not Linux. Read more at
http://www.gnu.org/gnu/why-gnu-linux.html.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: svn commit: rev 5522 - in trunk/subversion: libsvn_client tests/clients/cmdline
Posted by Robert Pluim <rp...@bigfoot.com>.
Robert Pluim writes:
> Brian Denny writes:
> > On Wed, Apr 02, 2003 at 10:25:58AM -0600, kraai@tigris.org wrote:
> > > * subversion/tests/clients/cmdline/diff_tests.py
> > > (diff_nonextant_urls): New.
> >
> > does this test pass for you? it fails for me.
> >
>
> It passes for me. Let me investigate and get back to you.
Repeat after me: when testing tests, start from a _completely clean_
setup. I'd removed the sbox.build() earlier because I was under the
mistaken impression that it only created the working copy, not the
repository as well.
Re: svn commit: rev 5522 - in trunk/subversion: libsvn_client tests/clients/cmdline
Posted by Robert Pluim <rp...@bigfoot.com>.
Brian Denny writes:
> On Wed, Apr 02, 2003 at 10:25:58AM -0600, kraai@tigris.org wrote:
> > * subversion/tests/clients/cmdline/diff_tests.py
> > (diff_nonextant_urls): New.
>
> does this test pass for you? it fails for me.
>
It passes for me. Let me investigate and get back to you.
> > + if not re.match('svn: Filesystem has no item$', err_output[0]):
> > + raise svntest.Failure
> > +
> > + diff_output, err_output = svntest.main.run_svn(None, 'diff', extant_url,
> > + non_extant_url)
> > + if not re.match('svn: Filesystem has no item$', err_output[0]):
> > + raise svntest.Failure
>
> here is the output i get when i run the test. it looks like svn diff
> *is* erroring against the non-existant URL, but with a different error
> string than what the test is checking for.
>
> subversion/libsvn_ra_local/ra_plugin.c:249: (apr_err=180000)
> svn: Couldn't find a repository.
> svn: Unable to open an ra_local session to URL
> subversion/libsvn_ra_local/split_url.c:153: (apr_err=180000)
> svn: svn_ra_local__split_URL: Unable to find valid repository
> (file:///usr/local/src/subversion/subversion/tests/clients/cmdline/repositories/diff_tests-12/A/does_not_exist)
> FAIL: diff_tests.py 12: svn diff errors against a non-existant URL
>
--
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org