~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_permissions.py

  • Committer: John Arbash Meinel
  • Date: 2006-09-05 20:58:28 UTC
  • mto: (1946.2.8 reduce-knit-churn)
  • mto: This revision was merged to the branch mainline in revision 1988.
  • Revision ID: john@arbash-meinel.com-20060905205828-6b69f9a2e2fb8100
Run the full test suite, and fix up any deprecation warnings.
That includes some Store tests that used to try and pass a string for the
file-like object.

Show diffs side-by-side

added added

removed removed

Lines of Context:
33
33
import os
34
34
import sys
35
35
import stat
36
 
from StringIO import StringIO
 
36
from cStringIO import StringIO
37
37
 
38
38
from bzrlib.branch import Branch
39
39
from bzrlib.bzrdir import BzrDir
156
156
        #                    extra chmod calls aren't being made
157
157
        try:
158
158
            transport = get_transport(self.get_url())
159
 
            transport.put('my-lock', StringIO(''))
 
159
            transport.put_bytes('my-lock', '')
160
160
            lockable = LockableFiles(transport, 'my-lock', TransportLock)
161
161
            self.assertNotEqual(None, lockable._dir_mode)
162
162
            self.assertNotEqual(None, lockable._file_mode)
276
276
            self.assertTransportMode(t, 'a', 0666 &~umask)
277
277
 
278
278
            # but Transport overrides umask
279
 
            t.put('b', 'txt', mode=0666)
 
279
            t.put_bytes('b', 'txt', mode=0666)
280
280
            self.assertTransportMode(t, 'b', 0666)
281
281
 
282
282
            t._sftp.mkdir('c', mode=0777)