~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_info.py

  • Committer: Aaron Bentley
  • Date: 2007-07-06 21:20:10 UTC
  • mto: (1551.19.24 Aaron's mergeable stuff)
  • mto: This revision was merged to the branch mainline in revision 2600.
  • Revision ID: abentley@panoramicfeedback.com-20070706212010-yesdnjys9484lftu
Provide ways of getting at unicode-clean output

Show diffs side-by-side

added added

removed removed

Lines of Context:
14
14
# along with this program; if not, write to the Free Software
15
15
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
16
16
 
 
17
from urllib import quote
17
18
 
18
19
from bzrlib import (
19
20
    branch as _mod_branch,
247
248
        locs.add_url('c', 'file:///home/bar/bar')
248
249
        locs.add_url('d', 'http://example.com/example/')
249
250
        locs.add_url('e', None)
250
 
        self.assertEqual(locs.urls, [('a', '.'),
 
251
        self.assertEqual(locs.locs, [('a', '.'),
251
252
                                     ('b', 'bar'),
252
253
                                     ('c', '/home/bar/bar'),
253
254
                                     ('d', 'http://example.com/example/')])
 
255
        self.assertEqualDiff('  a: .\n  b: bar\n  c: /home/bar/bar\n'
 
256
                             '  d: http://example.com/example/\n',
 
257
                             ''.join(locs.get_lines()))
254
258
 
255
259
    def test_gather_related_braches(self):
256
260
        branch = self.make_branch('.')
261
265
        self.assertEqual(
262
266
            [('public branch', 'baz'), ('push branch', 'bar'),
263
267
             ('parent branch', 'foo'), ('submit branch', 'qux')],
264
 
            info._gather_related_branches(branch).urls)
 
268
            info._gather_related_branches(branch).locs)