/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/tests/test_lockable_files.py

  • Committer: Jelmer Vernooij
  • Date: 2017-05-22 00:56:52 UTC
  • mfrom: (6621.2.26 py3_pokes)
  • Revision ID: jelmer@jelmer.uk-20170522005652-yjahcr9hwmjkno7n
Merge Python3 porting work ('py3 pokes')

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
16
16
 
17
17
import breezy
18
 
from breezy import (
 
18
from .. import (
19
19
    errors,
20
20
    lockdir,
21
21
    osutils,
22
22
    transport,
23
23
    )
24
 
from breezy.lockable_files import LockableFiles, TransportLock
25
 
from breezy.tests import (
 
24
from ..lockable_files import LockableFiles, TransportLock
 
25
from . import (
26
26
    TestCaseInTempDir,
27
27
    TestNotApplicable,
28
28
    )
29
 
from breezy.tests.test_smart import TestCaseWithSmartMedium
30
 
from breezy.tests.test_transactions import DummyWeave
31
 
from breezy.transactions import (PassThroughTransaction,
32
 
                                 ReadOnlyTransaction,
33
 
                                 WriteTransaction,
34
 
                                 )
 
29
from .test_smart import TestCaseWithSmartMedium
 
30
from .test_transactions import DummyWeave
 
31
from ..transactions import (PassThroughTransaction,
 
32
                            ReadOnlyTransaction,
 
33
                            WriteTransaction,
 
34
                            )
35
35
 
36
36
 
37
37
# these tests are applied in each parameterized suite for LockableFiles
323
323
        lockable = LockableFiles(self.transport.clone('readonly'), 'test-lock',
324
324
                                 lockdir.LockDir)
325
325
        # The directory mode should be read-write-execute for the current user
326
 
        self.assertEqual(00700, lockable._dir_mode & 00700)
 
326
        self.assertEqual(0o0700, lockable._dir_mode & 0o0700)
327
327
        # Files should be read-write for the current user
328
 
        self.assertEqual(00600, lockable._file_mode & 00700)
 
328
        self.assertEqual(0o0600, lockable._file_mode & 0o0700)
329
329
 
330
330
 
331
331
class TestLockableFiles_RemoteLockDir(TestCaseWithSmartMedium,