~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_graph.py

  • Committer: Aaron Bentley
  • Date: 2007-06-19 14:49:06 UTC
  • mto: This revision was merged to the branch mainline in revision 2537.
  • Revision ID: abentley@panoramicfeedback.com-20070619144906-zx160g6h377j729h
Fix handling of null revision

Show diffs side-by-side

added added

removed removed

Lines of Context:
14
14
# along with this program; if not, write to the Free Software
15
15
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
16
16
 
17
 
from bzrlib import graph
 
17
from bzrlib import (
 
18
    errors,
 
19
    graph,
 
20
    )
18
21
from bzrlib.revision import NULL_REVISION
19
22
from bzrlib.tests import TestCaseWithMemoryTransport
20
23
 
170
173
        ancestry_1 should always have a single common ancestor
171
174
        """
172
175
        graph = self.make_graph(ancestry_1)
 
176
        self.assertRaises(errors.InvalidRevisionId, graph.find_lca, None)
173
177
        self.assertEqual(set([NULL_REVISION]),
174
178
                         graph.find_lca(NULL_REVISION, NULL_REVISION))
175
179
        self.assertEqual(set([NULL_REVISION]),