~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/benchmarks/bench_status.py

  • Committer: John Arbash Meinel
  • Date: 2007-05-04 18:59:36 UTC
  • mto: This revision was merged to the branch mainline in revision 2643.
  • Revision ID: john@arbash-meinel.com-20070504185936-1mjdoqmtz74xe5mg
A C implementation of _fields_to_entry_0_parents drops the time from 400ms to 330ms for a 21k-entry tree

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
 
22
22
 
23
23
class StatusBenchmark(Benchmark):
24
 
    """Benchmarks for ``'bzr status'``."""
25
24
 
26
25
    def test_no_ignored_unknown_kernel_like_tree(self):
27
26
        """Status in a kernel sized tree with no ignored or unknowns.
42
41
        of a single file."""
43
42
        self.make_kernel_like_committed_tree()
44
43
        #XXX depends on the filenames generated by make_kernel_like_tree
45
 
        self.time(self.run_bzr, ['status', '7/4/0/16'])
 
44
        self.time(self.run_bzr, 'status', '7/4/0/16')
46
45
 
47
46
    def test_status_one_added_file_kernel_like_tree(self):
48
47
        """Status of a single added file in our stock large tree."""
49
48
        self.make_kernel_like_tree()
50
49
        self.run_bzr('add')
51
 
        self.run_bzr(['commit', '-m', 'initial import'])
52
 
        self.time(self.run_bzr, ['status', '3/3/3/10'])
 
50
        self.run_bzr('commit', '-m', 'initial import')
 
51
        self.time(self.run_bzr, 'status', '3/3/3/10')