~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_remote.py

  • Committer: John Arbash Meinel
  • Date: 2011-08-09 14:18:05 UTC
  • mto: (6015.9.8 2.4)
  • mto: This revision was merged to the branch mainline in revision 6066.
  • Revision ID: john@arbash-meinel.com-20110809141805-9lq771mvpsukl0pe
Catch a couple more cases that test tag fetching.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1183
1183
        client.add_expected_call(
1184
1184
            'Branch.last_revision_info', ('quack/',),
1185
1185
            'success', ('ok', '1', 'rev-tip'))
 
1186
        client.add_expected_call(
 
1187
            'Branch.get_config_file', ('quack/',),
 
1188
            'success', ('ok',), '')
 
1189
        transport.mkdir('quack')
 
1190
        transport = transport.clone('quack')
 
1191
        branch = self.make_remote_branch(transport, client)
 
1192
        result = branch.heads_to_fetch()
 
1193
        self.assertFinished(client)
 
1194
        self.assertEqual((set(['rev-tip']), set()), result)
 
1195
 
 
1196
    def test_uses_last_revision_info_and_tags_when_set(self):
 
1197
        transport = MemoryTransport()
 
1198
        client = FakeClient(transport.base)
 
1199
        client.add_expected_call(
 
1200
            'Branch.get_stacked_on_url', ('quack/',),
 
1201
            'error', ('NotStacked',))
 
1202
        client.add_expected_call(
 
1203
            'Branch.last_revision_info', ('quack/',),
 
1204
            'success', ('ok', '1', 'rev-tip'))
 
1205
        client.add_expected_call(
 
1206
            'Branch.get_config_file', ('quack/',),
 
1207
            'success', ('ok',), 'branch.fetch_tags = True')
1186
1208
        # XXX: this will break if the default format's serialization of tags
1187
1209
        # changes, or if the RPC for fetching tags changes from get_tags_bytes.
1188
1210
        client.add_expected_call(