/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_send.py

  • Committer: Gustav Hartvigsson
  • Date: 2021-01-09 21:36:27 UTC
  • Revision ID: gustav.hartvigsson@gmail.com-20210109213627-h1xwcutzy9m7a99b
Added 'Case Preserving Working Tree Use Cases' from Canonical Wiki

* Addod a page from the Canonical Bazaar wiki
  with information on the scmeatics of case
  perserving filesystems an a case insensitive
  filesystem works.
  
  * Needs re-work, but this will do as it is the
    same inforamoton as what was on the linked
    page in the currint documentation.

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
# along with this program; if not, write to the Free Software
16
16
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17
17
 
 
18
from io import (
 
19
    BytesIO,
 
20
    )
18
21
 
19
22
from ... import (
20
23
    branch,
22
25
    tests,
23
26
    )
24
27
from ...controldir import ControlDir
25
 
from ...bundle import serializer
26
 
from ...sixish import (
27
 
    BytesIO,
28
 
    )
 
28
from ...bzr.bundle import serializer
29
29
from ...transport import memory
30
30
from .. import (
31
31
    scenarios,
32
32
    )
33
 
from ..matchers import ContainsNoVfsCalls
34
33
 
35
34
 
36
35
load_tests = scenarios.load_tests_apply_scenarios
448
447
 
449
448
    _default_command = ['bundle-revisions', '../parent']
450
449
 
451
 
 
452
 
class TestSmartServerSend(tests.TestCaseWithTransport):
453
 
 
454
 
    def test_send(self):
455
 
        self.setup_smart_server_with_call_log()
456
 
        t = self.make_branch_and_tree('branch')
457
 
        self.build_tree_contents([('branch/foo', b'thecontents')])
458
 
        t.add("foo")
459
 
        t.commit("message")
460
 
        local = t.controldir.sprout('local-branch').open_workingtree()
461
 
        self.build_tree_contents([('branch/foo', b'thenewcontents')])
462
 
        local.commit("anothermessage")
463
 
        self.reset_smart_call_log()
464
 
        out, err = self.run_bzr(
465
 
            ['send', '-o', 'x.diff', self.get_url('branch')], working_dir='local-branch')
466
 
        # This figure represent the amount of work to perform this use case. It
467
 
        # is entirely ok to reduce this number if a test fails due to rpc_count
468
 
        # being too low. If rpc_count increases, more network roundtrips have
469
 
        # become necessary for this use case. Please do not adjust this number
470
 
        # upwards without agreement from bzr's network support maintainers.
471
 
        self.assertLength(7, self.hpss_calls)
472
 
        self.assertLength(1, self.hpss_connections)
473
 
        self.assertThat(self.hpss_calls, ContainsNoVfsCalls)