~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/benchmarks/bench_commit.py

  • Committer: Robert Collins
  • Date: 2006-06-09 09:18:56 UTC
  • mfrom: (1725.2.9 commit)
  • mto: This revision was merged to the branch mainline in revision 1757.
  • Revision ID: robertc@robertcollins.net-20060609091856-2f9fc48998d655a9
(robertc, ab)Merge some commit and fetch tuning steps.

Show diffs side-by-side

added added

removed removed

Lines of Context:
17
17
 
18
18
 
19
19
from bzrlib.benchmarks import Benchmark
 
20
from bzrlib.transport.memory import MemoryServer
 
21
from bzrlib.transport import get_transport
20
22
 
21
23
 
22
24
class CommitBenchmark(Benchmark):
23
25
 
24
26
    def test_commit_kernel_like_tree(self):
25
27
        """Commit of a fresh import of a clean kernel sized tree."""
 
28
        # uncomment this to run the benchmark with the repository in memory
 
29
        # not disk
 
30
        # self.transport_server = MemoryServer
 
31
        # self.make_kernel_like_tree(self.get_url())
26
32
        self.make_kernel_like_tree()
27
33
        self.run_bzr('add')
28
34
        # on robertc's machine the first sample of this took 59750ms/77682ms
 
35
        # after initial call reduction                       53922ms/73918ms
29
36
        self.time(self.run_bzr, 'commit', '-m', 'first post')