]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
Comment out bad/unfinished test code.
authorDaira Hopwood <daira@jacaranda.org>
Tue, 22 Sep 2015 15:43:43 +0000 (16:43 +0100)
committerDaira Hopwood <daira@jacaranda.org>
Tue, 22 Sep 2015 15:43:43 +0000 (16:43 +0100)
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
src/allmydata/test/test_magic_folder.py

index afb76d2511cf74f807b9c27bd245b4c22b81cba6..319593f5c73cfc068afd2f1b4846a5f7cfbc7be5 100644 (file)
@@ -160,21 +160,22 @@ class MagicFolderTestMixin(MagicFolderCLITestMixin, ShouldFailMixin, ReallyEqual
         d.addCallback(lambda ign: self.failUnlessReallyEqual(self._get_count('uploader.directories_created'), 2))
 
         # Files that are moved out of the upload directory should no longer be watched.
-        def _move_dir_away(ign):
-            os.rename(new_empty_tree_dir, empty_tree_dir)
-            # Wuh? Why don't we get this event for the real test?
-            #self.notify(to_filepath(new_empty_tree_dir), self.inotify.IN_MOVED_FROM)
-        d.addCallback(_move_dir_away)
-        def create_file(val):
-            test_file = abspath_expanduser_unicode(u"what", base=empty_tree_dir)
-            fileutil.write(test_file, "meow")
-            return
-        d.addCallback(create_file)
-        d.addCallback(lambda ign: time.sleep(1))
-        d.addCallback(lambda ign: self.failUnlessReallyEqual(self._get_count('uploader.objects_succeeded'), 4))
-        d.addCallback(lambda ign: self.failUnlessReallyEqual(self._get_count('uploader.files_uploaded'), 2))
-        d.addCallback(lambda ign: self.failUnlessReallyEqual(self._get_count('uploader.objects_queued'), 0))
-        d.addCallback(lambda ign: self.failUnlessReallyEqual(self._get_count('uploader.directories_created'), 2))
+        #def _move_dir_away(ign):
+        #    os.rename(new_empty_tree_dir, empty_tree_dir)
+        #    # Wuh? Why don't we get this event for the real test?
+        #    #self.notify(to_filepath(new_empty_tree_dir), self.inotify.IN_MOVED_FROM)
+        #d.addCallback(_move_dir_away)
+        #def create_file(val):
+        #    test_file = abspath_expanduser_unicode(u"what", base=empty_tree_dir)
+        #    fileutil.write(test_file, "meow")
+        #    #self.notify(...)
+        #    return
+        #d.addCallback(create_file)
+        #d.addCallback(lambda ign: time.sleep(1))  # XXX ICK
+        #d.addCallback(lambda ign: self.failUnlessReallyEqual(self._get_count('uploader.objects_succeeded'), 4))
+        #d.addCallback(lambda ign: self.failUnlessReallyEqual(self._get_count('uploader.files_uploaded'), 2))
+        #d.addCallback(lambda ign: self.failUnlessReallyEqual(self._get_count('uploader.objects_queued'), 0))
+        #d.addCallback(lambda ign: self.failUnlessReallyEqual(self._get_count('uploader.directories_created'), 2))
 
         d.addBoth(self.cleanup)
         return d