From d31d7ff9415fa75bb1f500ddc9ccfab7a2fbf7be Mon Sep 17 00:00:00 2001 From: Brian Warner Date: Wed, 19 Sep 2007 01:43:44 -0700 Subject: [PATCH] test_system.py: do a large-file test (1.5MB) to trigger pauseProducing --- src/allmydata/test/test_system.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/allmydata/test/test_system.py b/src/allmydata/test/test_system.py index 4577dc89..b3e57ca1 100644 --- a/src/allmydata/test/test_system.py +++ b/src/allmydata/test/test_system.py @@ -576,6 +576,12 @@ class SystemTest(testutil.SignalMixin, unittest.TestCase): "new.txt contents")) d.addCallback(lambda res: self.GET("vdrive/global/subdir3/new.txt")) d.addCallback(self.failUnlessEqual, "new.txt contents") + # and again with something large enough to use multiple segments, + # and hopefully trigger pauseProducing too + d.addCallback(lambda res: self.PUT("vdrive/global/subdir3/big.txt", + "big" * 500000)) # 1.5MB + d.addCallback(lambda res: self.GET("vdrive/global/subdir3/big.txt")) + d.addCallback(lambda res: self.failUnlessEqual(len(res), 1500000)) # can we replace files in place? d.addCallback(lambda res: self.PUT("vdrive/global/subdir3/new.txt", -- 2.45.2