2014/1/14 <
msiko...@gmail.com>:
> Hello,
> I've been using RF for several months and found it very useful - thanks for
> great tool.
> Now I've decided to join this group share my experience and get some help.
Thanks for compliments and welcome aboard!
> I have a big set of test cases in suite and execution takes quite a long
> time.
> I'd like to print a console message with current suite progress at the end
> of every test (so far there is only 1 suite).
Yeah, this would be a handy generic feature. There's even an old issue about it:
http://code.google.com/p/robotframework/issues/detail?id=318
The main problem implementing the above issue is that updating the
console so that all relevant information is easily visible is hard in
generic manner. Python's `curses` module ought to support it, but it
doesn't work on Windows and I doubt it works with Jython either. If
anyone has ideas how to implement this, please let us know!
> Counting current test number is not a problem but is there a way to get a
> total number of test cases to be executed?
> Pybot is run by shell script and I'm allowing user to pass test name pattern
> to '--tests' so total number of tests will vary for
> each run.
> I wonder if there is any special variable or another way to get this total
> number o test cases to be executed at the beginning of suite execution.
> I was searching group but didn't find topic which will exactly answer my
> problem.
The easiest way to implement this yourself is using the listener interface:
http://robotframework.googlecode.com/hg/doc/userguide/RobotFrameworkUserGuide.html#using-listener-interface
Every start_suite method gets the amount of tests in that suite,
recursively, and by listening to start_test you can count which tests
is running.
Cheers,
.peke
--
Agile Tester/Developer/Consultant ::
http://eliga.fi
Lead Developer of Robot Framework ::
http://robotframework.org