Hi Holger, <br> you are absolutely right!!! I was just messing it up with my code.<br> <br>So briefly, it works fine in a console and inside the Maya console using the plugins, so I can now select and deselect the tests...<br>
Thanks you so much for you help, and congratulation for the tool, it's being very useful here<br><br>best regards<br>Fede<br><br><br><br><div class="gmail_quote">On 12 October 2009 19:50, holger krekel <span dir="ltr"><holger@merlinux.eu></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi Fede,<br>
<div class="im"><br>
On Mon, Oct 12, 2009 at 16:26 +1100, Fede Naum wrote:<br>
> Hi Holger, and all, Thank you so much for the quick response, and sorry I<br>
> could not come back with the results earlier.<br>
><br>
> The "runtesthelper.py" works fine to run tests in a console and inside Maya<br>
> without using any plugin.<br>
> But I need to use the *keyword* plugin because I have to select some test<br>
> that runs inside maya, and deselect other that run in another<br>
> application....<br>
<br>
</div>i think the keyword plugin is enabled by default. When i run<br>
<br>
runtesthelper.pytest(['--traceconfig', ...])<br>
<br>
the keyword plugin should be in the "active plugins" section.<br>
<div class="im"><br>
> I was registering it with the following code. (likely not to be the best<br>
> way, and as you said it's kind of a hack using py.test.config,)<br>
><br>
> import os, py<br>
> os.environ['PYTEST_PLUGINS'] = 'keyword'<br>
> py.test.config.pluginmanager.consider_env()<br>
> py.test.config.pluginmanager.do_configure(py.test.config)<br>
><br>
> but now when I used the "runtesthelper.py" I got an error, so I could not<br>
> manage yet to read the keyword plugin and then execute my tests.<br>
<br>
</div>If you need to add plugins setting os.environ should be<br>
enough. the startup of py.test (even through the<br>
runtesthelper script) takes care to load plugins.<br>
but again, i think there is no need to load the 'keyword'<br>
plugin in particular.<br>
<div class="im"><br>
> You were saying that py.test.config is kind of deprecated.?..so, what should<br>
> I use instead? Or what will be the correct way to register a plugin from<br>
> inside a console and then run the test using your "runtesthelper.py"<br>
<br>
</div>plugin methods can get access to the config object.<br>
<br>
> Thanks a lot<br>
> Fede<br>
<br>
welcome.<br>
<font color="#888888">holger<br>
</font></blockquote></div><br>