/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/tests/blackbox/test_cat.py

  • Committer: Breezy landing bot
  • Author(s): Jelmer Vernooij
  • Date: 2020-06-19 22:18:01 UTC
  • mfrom: (7515.1.1 merge-3.1)
  • Revision ID: breezy.the.bot@gmail.com-20200619221801-6chb6w22ctckkajl
Merge lp:brz/3.1.

Merged from https://code.launchpad.net/~jelmer/brz/merge-3.1/+merge/386125

Show diffs side-by-side

added added

removed removed

Lines of Context:
19
19
"""
20
20
 
21
21
from ... import tests
22
 
from ...bzr.tests.matchers import ContainsNoVfsCalls
23
22
from ...transport import memory
24
23
 
25
24
 
214
213
        url = self.get_readonly_url() + '/a'
215
214
        out, err = self.run_bzr(['cat', '-d', url, 'README'])
216
215
        self.assertEqual('contents of a/README\n', out)
217
 
 
218
 
 
219
 
class TestSmartServerCat(tests.TestCaseWithTransport):
220
 
 
221
 
    def test_simple_branch_cat(self):
222
 
        self.setup_smart_server_with_call_log()
223
 
        t = self.make_branch_and_tree('branch')
224
 
        self.build_tree_contents([('branch/foo', b'thecontents')])
225
 
        t.add("foo")
226
 
        t.commit("message")
227
 
        self.reset_smart_call_log()
228
 
        out, err = self.run_bzr(['cat', "%s/foo" % self.get_url('branch')])
229
 
        # This figure represent the amount of work to perform this use case. It
230
 
        # is entirely ok to reduce this number if a test fails due to rpc_count
231
 
        # being too low. If rpc_count increases, more network roundtrips have
232
 
        # become necessary for this use case. Please do not adjust this number
233
 
        # upwards without agreement from bzr's network support maintainers.
234
 
        self.assertLength(9, self.hpss_calls)
235
 
        self.assertLength(1, self.hpss_connections)
236
 
        self.assertThat(self.hpss_calls, ContainsNoVfsCalls)