Rev 6057: (vila) os.fdatasync is not defined on BSD-based OSes (Vincent Ladeuil) in file:///home/pqm/archives/thelove/bzr/%2Btrunk/

Canonical.com Patch Queue Manager pqm at pqm.ubuntu.com
Mon Aug 8 17:39:51 UTC 2011


At file:///home/pqm/archives/thelove/bzr/%2Btrunk/

------------------------------------------------------------
revno: 6057 [merge]
revision-id: pqm at pqm.ubuntu.com-20110808173945-vx1z3qi3c3qj50zv
parent: pqm at pqm.ubuntu.com-20110808045409-gtfs260inl0e6aq1
parent: v.ladeuil+lp at free.fr-20110808125116-mocdm1hb68nhifx9
committer: Canonical.com Patch Queue Manager <pqm at pqm.ubuntu.com>
branch nick: +trunk
timestamp: Mon 2011-08-08 17:39:45 +0000
message:
  (vila) os.fdatasync is not defined on BSD-based OSes (Vincent Ladeuil)
modified:
  bzrlib/tests/test_transport.py testtransport.py-20050718175618-e5cdb99f4555ddce
  doc/en/release-notes/bzr-2.5.txt bzr2.5.txt-20110708125756-587p0hpw7oke4h05-1
=== modified file 'bzrlib/tests/test_transport.py'
--- a/bzrlib/tests/test_transport.py	2011-08-02 01:10:27 +0000
+++ b/bzrlib/tests/test_transport.py	2011-08-08 12:44:51 +0000
@@ -748,6 +748,10 @@
         We can't easily observe the external effect but we can at least see
         it's called.
         """
+        sentinel = object()
+        fdatasync = getattr(os, 'fdatasync', sentinel)
+        if fdatasync is sentinel:
+            raise tests.TestNotApplicable('fdatasync not supported')
         t = self.get_transport('.')
         calls = self.recordCalls(os, 'fdatasync')
         w = t.open_write_stream('out')

=== modified file 'doc/en/release-notes/bzr-2.5.txt'
--- a/doc/en/release-notes/bzr-2.5.txt	2011-08-06 03:52:34 +0000
+++ b/doc/en/release-notes/bzr-2.5.txt	2011-08-08 12:51:16 +0000
@@ -156,6 +156,9 @@
   due to the order that `build_snapshot` performs its actions.
   (Andrew Bennetts)
 
+* Don't require ``os.fdatasync`` to be defined on all supported OSes
+  (BSD-based OSes don't define it).  (Vincent Ladeuil, #822649)
+
 * Fix compatibility with testtools 0.9.12. (Jelmer Vernooij, #815423)
 
 * `TestCaseWithMemoryTransport` is faster now: `_check_safety_net` now




More information about the bazaar-commits mailing list