]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
cli: tests: skip symlink test if there is no os.symlink
authorZooko O'Whielacronx <zooko@zooko.com>
Thu, 15 Jan 2009 01:10:10 +0000 (18:10 -0700)
committerZooko O'Whielacronx <zooko@zooko.com>
Thu, 15 Jan 2009 01:10:10 +0000 (18:10 -0700)
src/allmydata/test/test_cli.py

index 5fd09b552df605194377e08daf192a9c7f35e06d..228568666c3416b746253541447f405773634ded 100644 (file)
@@ -602,6 +602,8 @@ class Cp(SystemTestMixin, CLITestMixin, unittest.TestCase):
     test_unicode_filename.todo = "This behavior is not yet supported, although it does happen to work (for reasons that are ill-understood) on many platforms.  See issue ticket #534."
 
     def test_dangling_symlink_vs_recursion(self):
+        if not hasattr(os, 'symlink'):
+            raise unittest.SkipTest("There is no symlink on this platform.")
         # cp -r on a directory containing a dangling symlink shouldn't assert
         self.basedir = os.path.dirname(self.mktemp())
         dn = os.path.join(self.basedir, "dir")