[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

RE: Candidate bug in build process -- cannot pass tests building/testing as root

From: Charles Butterfield <charles.butterfield_at_nextcentury.com>
Date: Mon, 18 Feb 2008 00:19:12 -0500

Karl Fogel<kfogel_at_red-bean.com> writes:
> "Charles Butterfield" <charles.butterfield_at_nextcentury.com> writes:
> > When building 1.4.6 as root (under CentOS 5.1), one of the tests
fails,
> > and several tests are skipped.
>
> Skipping is normal -- it's intentional, and does not indicate failure.
> It just means the test suite isn't running that test, for some (known)
> reason.
>
> > The failed test is:
> > FAIL: switch_tests.py 17: refresh the WC file system read-only
> > attribute
>
> Interestingly, that test starts out by Skipping if it's running as
> root:
>
> def refresh_read_only_attribute(sbox):
> "refresh the WC file system read-only attribute "
>
> # This test will fail when run as root. Since that's normal
> # behavior, just skip the test.
> if os.name == 'posix':
> if os.geteuid() == 0:
> raise svntest.Skip

That's interesting. My copy of the code is missing the conditional
logic, as shown below:
# Issue 2306.
def refresh_read_only_attribute(sbox):
  "refresh the WC file system read-only attribute "
  sbox.build()
  wc_dir = sbox.wc_dir

>
> So something about that code isn't working for you on CentOS. Can you
> find out what it is? If you try "os.getuid" instead of "os.geteuid",
> does that change it? What does getlogin() return?

Here is the answer (but it's probably moot given the missing
conditional)

os.name = posix
os.geteuid = 0
os.getuid = 0
os.getlogin = root

-- 
Charlie
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-02-18 06:19:22 CET

This is an archived mail posted to the Subversion Dev mailing list.