~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/blackbox/test_pack.py

  • Committer: Patch Queue Manager
  • Date: 2011-11-28 05:07:40 UTC
  • mfrom: (6305.2.7 hpss-pack)
  • Revision ID: pqm@pqm.ubuntu.com-20111128050740-md31i70uhigil8mq
(jelmer) Add HPSS call for ``Repository.pack``. (Jelmer Vernooij)

Show diffs side-by-side

added added

removed removed

Lines of Context:
83
83
 
84
84
        pack_names = transport.list_dir('repository/obsolete_packs')
85
85
        self.assertTrue(len(pack_names) == 0)
 
86
 
 
87
 
 
88
class TestSmartServerPack(tests.TestCaseWithTransport):
 
89
 
 
90
    def test_simple_pack(self):
 
91
        self.setup_smart_server_with_call_log()
 
92
        t = self.make_branch_and_tree('branch')
 
93
        self.build_tree_contents([('branch/foo', 'thecontents')])
 
94
        t.add("foo")
 
95
        t.commit("message")
 
96
        self.reset_smart_call_log()
 
97
        out, err = self.run_bzr(['pack', self.get_url('branch')])
 
98
        # This figure represent the amount of HPSS calls to perform this use
 
99
        # case. It is entirely ok to reduce this number if a test fails due to
 
100
        # rpc_count # being too low. If rpc_count increases, more network
 
101
        # roundtrips have become necessary for this use case. Please do not
 
102
        # adjust this number upwards without agreement from bzr's network
 
103
        # support maintainers.
 
104
        self.assertLength(6, self.hpss_calls)