<div dir="ltr"><div>Gaurav, </div><div><br></div>What you think about this?<br><br><div class="gmail_quote">---------- Forwarded message ----------<br>From: <b class="gmail_sendername">Martin Abente Lahaye</b> <span dir="ltr"><<a href="mailto:notifications@github.com">notifications@github.com</a>></span><br>
Date: Mon, Aug 4, 2014 at 3:27 PM<br>Subject: Re: [sugar-toolkit-gtk3] Add a testing method to open a activity with a uri (e2c20bb)<br>To: godiard/sugar-toolkit-gtk3 <<a href="mailto:sugar-toolkit-gtk3@noreply.github.com">sugar-toolkit-gtk3@noreply.github.com</a>><br>
Cc: Gonzalo Odiard <<a href="mailto:godiard@gmail.com">godiard@gmail.com</a>><br><br><br><p>What do you think about extending run_activity with an extra "options" parameter, like:</p>

<pre><code>def run_activity(self, options=None):
    ...
    cmd = ["sugar-launch", self.bundle_id]
    if options is not None:
        cmd += options
    process = subprocess.Popen(cmd)
    ...
</code></pre>

<p>Then, we don't need to repeat most of the run_activity code elsewhere, we can cover other options in the future, and run_activity_with_uri can be re-factored as:</p>

<pre><code>def run_activity_with_uri(self, uri):
    self.run_activity(['--uri', uri])
</code></pre>

<p style="font-size:small;color:#666">—<br>Reply to this email directly or <a href="https://github.com/godiard/sugar-toolkit-gtk3/commit/e2c20bbc1c02506d229ff50b1e813e4321f78609#commitcomment-7258427" target="_blank">view it on GitHub</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/4050778__eyJzY29wZSI6Ik5ld3NpZXM6QmVhY29uIiwiZXhwaXJlcyI6MTcyMjc5NjA0NywiZGF0YSI6eyJpZCI6Mzg3NzA0MDl9fQ==--4240f42abbeee9160e2fb2208bdbb2a49bfe580f.gif" width="1"></p>
</div><br><br clear="all"><div><br></div>-- <br>Gonzalo Odiard<br><br>
</div>