[BUG] bzr-0.1-rc1: selftest failed on Windows
Robert Collins
robertc at robertcollins.net
Mon Oct 10 01:04:07 BST 2005
On Sun, 2005-10-09 at 10:57 +1000, Martin Pool wrote:
> On 09/10/05, Alexander Belchenko <bialix at ukr.net> wrote:
> > I discover that in testinv.py class TestEntryDiffing in setUp method
> > have following statements:
> >
> > if has_symlinks():
> > self.link_1 = self.inv_1['linkid']
> > self.link_2 = self.inv_2['linkid']
> >
> > Function has_symlinks() from osutils.py return False if standard module
> > os have not attribute symlink. On Windows this module have not this
> > attributes. What need to do in this situation? Disable test or redesign
> > them?
>
> For now I think disable the test, based on something like hasattr(os,
> 'has_symlinks').
Uhm, has_symlinks is the test to do that.
its just
if osutils.has_symlinks():
# symlink logic here.
--- bzrlib/selftest/testinv.py
+++ bzrlib/selftest/testinv.py
@@ -196,6 +196,8 @@
"\n")
def test_link_diff_deleted(self):
+ if not has_symlinks():
+ return
output = StringIO()
self.link_1.diff(internal_diff,
"old_label", self.tree_1,
@@ -205,6 +207,8 @@
"=== target was 'target1'\n")
def test_link_diff_added(self):
+ if not has_symlinks():
+ return
output = StringIO()
self.link_1.diff(internal_diff,
"new_label", self.tree_1,
@@ -214,6 +218,8 @@
"=== target is 'target1'\n")
def test_link_diff_changed(self):
+ if not has_symlinks():
+ return
output = StringIO()
self.link_1.diff(internal_diff,
"/dev/null", self.tree_1,
Cheers,
Rob
--
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20051010/a4b27031/attachment.pgp
More information about the bazaar
mailing list