Anton Shestakov <av6@dwimlabs.net>, Thu, 08 Sep 2016 18:41:11 +0800
pipelines: install Mercurial
Doesn't seem to be any way to catch "no such file or directory" error from lpc?
spec/hglib_spec.lua
Permissions: -rw-r--r--
local hglib = require('hglib') describe('hglib client', function() it('can connect using just file handles', function() local rh = io.open('spec/data/hello', 'rb') local client = hglib.Client.connect(rh, nil) assert.is_true(client.capabilities.getencoding) assert.is_true(client.capabilities.runcommand) assert.are_equal('UTF-8', client.encoding) assert.are_equal(3615, client.pid) assert.are_equal(3615, client.pgid) it('can launch a new cmdserver process', function() local client = hglib.Client.open() assert.is_true(client.capabilities.getencoding) assert.is_true(client.capabilities.runcommand) assert.are_equal('UTF-8', client.encoding) assert.are_equal('number', type(client.pid)) assert.are_equal('number', type(client.lpcpid)) it('can send getencoding command', function() local client = hglib.Client.open() local encoding, err = client:getencoding() assert.are_equal('string', type(encoding))