我正在hglib-erlang
为转换hglib-python
为 erlang 语言模块而写作。在 的文件中"test-push.py"
,有一个测试用例如下。
我认为第二个commit('second')
没有什么可提交的并给出错误信息。只有一个日志项('first')
。这样对吗?
class test_push(common.basetest):
def test_basic(self):
self.append('a', 'a')
self.client.commit('first', addremove=True)
self.client.clone(dest='other')
other = hglib.open('other')
# broken in hg, doesn't return 1 if nothing to push
#self.assertFalse(self.client.push('other'))
self.append('a', 'a')
self.client.commit('second')
self.assertTrue(self.client.push('other'))
self.assertEquals(self.client.log(), other.log())