view tests/test-paths.py @ 88:3bbf6a3266f4

test-summary: fix test due to bookmarks being separated from tags in hg >= 2.0
author Idan Kamara <idankk86@gmail.com>
date Fri, 18 Nov 2011 00:49:47 +0200
parents eac8be119d81
children e738d6fe5f3f
line wrap: on
line source

import common, os
import hglib

class test_paths(common.basetest):
    def test_basic(self):
        open('.hg/hgrc', 'a').write('[paths]\nfoo = bar\n')

        # hgrc isn't watched for changes yet, have to reopen
        self.client = hglib.open()
        paths = self.client.paths()
        self.assertEquals(len(paths), 1)
        self.assertEquals(paths['foo'], os.path.abspath('bar'))
        self.assertEquals(self.client.paths('foo'), os.path.abspath('bar'))