#12776 closed defect (fixed)
Tests fail with Subversion 1.6 or early: WindowsError: [Error 5] Access is denied
Reported by: | anonymous | Owned by: | Jun Omae |
---|---|---|---|
Priority: | normal | Milestone: | 1.0.14 |
Component: | admin/console | Version: | |
Severity: | minor | Keywords: | |
Cc: | Branch: | ||
Release Notes: |
Use |
||
API Changes: |
Move |
||
Internal Changes: |
Description
C:\Trac>svn checkout https://svn.edgewall.org/repos/trac/trunk C:\Trac>python trac\admin\tests\console.py SKIP: trac.admin.tests.console.TracAdminComponentTestCase (__name__ is not trac.admin.tests.console) ................................................................E. ====================================================================== ERROR: test_deploy (__main__.TracAdminDeployTestCase) Deploy into valid target directory. ---------------------------------------------------------------------- Traceback (most recent call last): File "trac\admin\tests\console.py", line 849, in tearDown shutil.rmtree(self.env.path) File "c:\Python27\Lib\shutil.py", line 247, in rmtree rmtree(fullname, ignore_errors, onerror) File "c:\Python27\Lib\shutil.py", line 247, in rmtree rmtree(fullname, ignore_errors, onerror) File "c:\Python27\Lib\shutil.py", line 247, in rmtree rmtree(fullname, ignore_errors, onerror) File "c:\Python27\Lib\shutil.py", line 247, in rmtree rmtree(fullname, ignore_errors, onerror) File "c:\Python27\Lib\shutil.py", line 252, in rmtree onerror(os.remove, fullname, sys.exc_info()) File "c:\Python27\Lib\shutil.py", line 250, in rmtree os.remove(fullname) WindowsError: [Error 5] Access is denied: 'c:\\users\\joe\\appdata\\local\\temp\\trac-testdir-gnhitw\\www\\htdocs\\common\\.svn\\all-wcprops' ---------------------------------------------------------------------- Ran 66 tests in 7.113s FAILED (errors=1)
Should deploy also copy the .svn
folders?
It works after upgrading C:\Trac
SVN checkout from to SVN 1.8 working copy format, where only C:\Trac\.svn
folder exists, not C:\TracSVN\trac\htdocs\.svn
.
Attachments (0)
Change History (9)
comment:1 by , 8 years ago
Type: | enhancement → defect |
---|
comment:2 by , 8 years ago
comment:3 by , 8 years ago
Component: | general → admin/console |
---|---|
Severity: | normal → minor |
Summary: | Tests fail with old SVN: WindowsError: [Error 5] Access is denied: 'c:\\users\\joe\\appdata\\local\\temp\\trac-testdir-gnhitw\\www\\htdocs\\common\\.svn\\all-wcprops' → Tests fail with Subversion 1.6 or early: WindowsError: [Error 5] Access is denied |
comment:4 by , 8 years ago
Milestone: | → 1.0.14 |
---|---|
Owner: | set to |
Status: | new → assigned |
os.remove()
doesn't work for read-only files on Windows. I consider we could always use rmtree
in trac.tests.compat
rather than shutil.rmtree
.
follow-up: 6 comment:5 by , 8 years ago
It might make sense to move rmtree
from trac.tests.compat
to trac.test
. It was moved there in r12247, but when I look now it seems like an odd place to have placed the function.
Should shutil.rmtree
in reset_db_and_disk
also be replaced with rmtree
?: tags/trac-1.2.1/trac/test.py@:487#L479.
comment:6 by , 8 years ago
Replying to Ryan J Ollos:
It might make sense to move
rmtree
fromtrac.tests.compat
totrac.test
. It was moved there in r12247, but when I look now it seems like an odd place to have placed the function.
I agree.
Should
shutil.rmtree
inreset_db_and_disk
also be replaced withrmtree
?: tags/trac-1.2.1/trac/test.py@:487#L479.
Ah. I missed it.
Revised 3 branches with your suggestions.
comment:8 by , 8 years ago
API Changes: | modified (diff) |
---|---|
Release Notes: | modified (diff) |
Resolution: | → fixed |
Status: | assigned → closed |
Thanks for the reviewing. Committed in [15799-15801].
#8278 was the same error.