~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_inv.py

  • Committer: John Arbash Meinel
  • Date: 2010-08-23 17:54:07 UTC
  • mfrom: (5387 +trunk)
  • mto: This revision was merged to the branch mainline in revision 5390.
  • Revision ID: john@arbash-meinel.com-20100823175407-yomx2h1x5v8amt6w
Merge bzr.dev 5387 in prep for NEWS

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2005, 2006, 2007, 2008, 2009 Canonical Ltd
 
1
# Copyright (C) 2005-2010 Canonical Ltd
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
18
18
from bzrlib import (
19
19
    chk_map,
20
20
    groupcompress,
21
 
    bzrdir,
22
21
    errors,
23
22
    inventory,
24
23
    osutils,
607
606
 
608
607
    def test_dir_detect_changes(self):
609
608
        left = inventory.InventoryDirectory('123', 'hello.c', ROOT_ID)
610
 
        left.text_sha1 = 123
611
 
        left.executable = True
612
 
        left.symlink_target='foo'
613
609
        right = inventory.InventoryDirectory('123', 'hello.c', ROOT_ID)
614
 
        right.text_sha1 = 321
615
 
        right.symlink_target='bar'
616
610
        self.assertEqual((False, False), left.detect_changes(right))
617
611
        self.assertEqual((False, False), right.detect_changes(left))
618
612
 
632
626
 
633
627
    def test_symlink_detect_changes(self):
634
628
        left = inventory.InventoryLink('123', 'hello.c', ROOT_ID)
635
 
        left.text_sha1 = 123
636
 
        left.executable = True
637
629
        left.symlink_target='foo'
638
630
        right = inventory.InventoryLink('123', 'hello.c', ROOT_ID)
639
 
        right.text_sha1 = 321
640
631
        right.symlink_target='foo'
641
632
        self.assertEqual((False, False), left.detect_changes(right))
642
633
        self.assertEqual((False, False), right.detect_changes(left))