Code review comment for lp:~le-chi-thu/lava-dispatcher/log_send_and_expect

Revision history for this message
Le Chi Thu (le-chi-thu) wrote :

Major args is only one element and Iit will print a string which look
better than to print an array of one element.

Merge conflict is resolved.

>>> args=["hello"]
>>> print "expect '%s'"%args[0]
expect 'hello'
>>> print "expect %s"%str(args)
expect ['hello']

On 9 December 2011 00:22, Paul Larson <email address hidden> wrote:

> Review: Approve
>
> 65 + if (kw.has_key('timeout')):
> 66 + timeout = kw['timeout']
> 67 + else:
> 68 + timeout = self.proc.timeout
> 69 +
> 70 + if len(args) == 1:
> 71 + logging.debug("expect (%d): '%s'" %(timeout, args[0]))
> 72 + else:
> 73 + logging.debug("expect (%d): '%s'" %(timeout, str(args)))
>
> We should combine these two blocks, no need to have this ambiguous check
> for len(args) == 1 if we just checked whether timeout was specified.
>
> Also, there is a small merge conflict to fix. Otherwise, still looks fine.
> --
>
> https://code.launchpad.net/~le-chi-thu/lava-dispatcher/log_send_and_expect/+merge/84673
> You are the owner of lp:~le-chi-thu/lava-dispatcher/log_send_and_expect.
>

« Back to merge proposal