~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/per_repository/test_commit_builder.py

  • Committer: Robert Collins
  • Date: 2010-04-08 04:34:03 UTC
  • mfrom: (5138 +trunk)
  • mto: This revision was merged to the branch mainline in revision 5139.
  • Revision ID: robertc@robertcollins.net-20100408043403-56z0d07vdqrx7f3t
Update bugfix for 528114 to trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
16
16
 
17
17
"""Tests for repository commit builder."""
18
18
 
19
 
from copy import copy
20
 
import errno
21
19
import os
22
 
import sys
23
20
 
24
21
from bzrlib import (
25
22
    errors,
 
23
    graph,
26
24
    inventory,
27
25
    osutils,
28
26
    repository,
29
27
    revision as _mod_revision,
30
28
    tests,
31
29
    )
32
 
from bzrlib.graph import Graph
33
 
from bzrlib.tests.per_repository import test_repository
34
 
 
35
 
 
36
 
class TestCommitBuilder(test_repository.TestCaseWithRepository):
 
30
from bzrlib.tests import per_repository
 
31
 
 
32
 
 
33
class TestCommitBuilder(per_repository.TestCaseWithRepository):
37
34
 
38
35
    def test_get_commit_builder(self):
39
36
        branch = self.make_branch('.')
924
921
        # (closest to a public per-file graph API we have today)
925
922
        tree.lock_read()
926
923
        self.addCleanup(tree.unlock)
927
 
        graph = dict(Graph(tree.branch.repository.texts).iter_ancestry([tip]))
928
 
        self.assertEqual(expected_graph, graph)
 
924
        g = dict(graph.Graph(tree.branch.repository.texts).iter_ancestry([tip]))
 
925
        self.assertEqual(expected_graph, g)
929
926
 
930
927
    def test_last_modified_revision_after_content_file_changes(self):
931
928
        # altering a file changes the last modified.