3 new revisions:

Revision: a062029a56ed
Branch:   default
Author:   Pekka Klärck
Date:     Mon Jun 10 07:07:40 2013
Log:      risto.py: pep8
http://code.google.com/p/robotframework/source/detail?r=a062029a56ed

Revision: 9bd2ab7ce7cd
Branch:   default
Author:   Pekka Klärck
Date:     Mon Jun 10 07:08:38 2013
Log:      risto docs: update preconditions, whitespace.
http://code.google.com/p/robotframework/source/detail?r=9bd2ab7ce7cd

Revision: 4a885ca9ae43
Branch:   default
Author:   Pekka Klärck
Date:     Mon Jun 10 07:08:53 2013
Log:      risto.py: 2.8 compatibility
http://code.google.com/p/robotframework/source/detail?r=4a885ca9ae43

==============================================================================
Revision: a062029a56ed
Branch:   default
Author:   Pekka Klärck
Date:     Mon Jun 10 07:07:40 2013
Log:      risto.py: pep8
http://code.google.com/p/robotframework/source/detail?r=a062029a56ed

Modified:
 /tools/ristopy/risto.py

=======================================
--- /tools/ristopy/risto.py     Thu Jun  6 07:00:44 2013
+++ /tools/ristopy/risto.py     Mon Jun 10 07:07:40 2013
@@ -153,7 +153,7 @@

     def _get_names(self, paths):
         paths = [os.path.splitext(os.path.abspath(p))[0] for p in paths]
-        path_tokens = [p.replace('\\','/').split('/') for p in paths]
+        path_tokens = [p.replace('\\', '/').split('/') for p in paths]
         min_tokens = min(len(t) for t in path_tokens)
         index = -1
         while self._tokens_are_same_at_index(path_tokens, index):
@@ -334,13 +334,13 @@

     def critical_tests(self, stats):
         if self._critical:
-            line =  {'linestyle': '--', 'linewidth': 1}
+            line = {'linestyle': '--', 'linewidth': 1}
             self._plot(self._indexes, stats, **line)
             self._legends.append(Legend(label='critical tests', **line))

     def all_tests(self, stats):
         if self._all:
-            line =  {'linestyle': ':', 'linewidth': 1}
+            line = {'linestyle': ':', 'linewidth': 1}
             self._plot(self._indexes, stats, **line)
             self._legends.append(Legend(label='all tests', **line))

@@ -485,7 +485,7 @@
             if line == '' or line.startswith('#'):
                 continue
             elif line.startswith('-'):
-                fargs.extend(line.split(' ',1))
+                fargs.extend(line.split(' ', 1))
             else:
                 fargs.append(line)
         args[index:index+2] = fargs
@@ -495,7 +495,7 @@
         opt_groups = []
         current = []
         for arg in args:
-            if arg.replace('-','') == '' and len(arg) >= 3:
+            if arg.replace('-', '') == '' and len(arg) >= 3:
                 opts = self._arg_parser.parse_args(current)[0]
                 opt_groups.append(opts)
                 current = []

==============================================================================
Revision: 9bd2ab7ce7cd
Branch:   default
Author:   Pekka Klärck
Date:     Mon Jun 10 07:08:38 2013
Log:      risto docs: update preconditions, whitespace.
http://code.google.com/p/robotframework/source/detail?r=9bd2ab7ce7cd

Modified:
 /tools/ristopy/doc/ristopy.txt

=======================================
--- /tools/ristopy/doc/ristopy.txt      Mon Oct 15 04:46:45 2012
+++ /tools/ristopy/doc/ristopy.txt      Mon Jun 10 07:08:38 2013
@@ -7,8 +7,8 @@
 :prog:`risto.py` is a tool for plotting graphs about test execution
 history based on statistics read from Robot Framework output files.
 Actual drawing is handled by Matplotlib tool, which must be installed
-separately. :prog:`risto.py` is included in source distributions and can also
-be downloaded from
+separately. :prog:`risto.py` is included in source distributions and can also
+be downloaded from
 http://code.google.com/p/robotframework/wiki/HistoricalReportingTool.

 .. contents::
@@ -18,12 +18,11 @@
 --------

 ::
-
+
   risto.py options input files
   risto.py options1 --- options2 --- optionsN --- input files
   risto.py --argumentfile path

-
 Options
 -------

@@ -33,8 +32,8 @@
   -P, --nopassed         Does not plot passed graphs.
   -F, --nofailed         Does not plot failed graphs.
-t, --tag <name> Adds graphs for these tags. The name can contain "\*"
-                         and "?" as wildcards. "AND" in the given name is
-                         converted to " & ", to make it easier to plot
+                         and "?" as wildcards. "AND" in the given name is
+                         converted to " & ", to make it easier to plot
                          combined tags.
-o, --output <path> The path to the image file to create. If not given,
                          the image is opened into Matplotlib viewer.
@@ -43,24 +42,23 @@
                          title.
   -w, --width <inches>   The width of the image. The default is 800.
   -h, --height <inches>  The height of the image. The default is 400.
-  -f, --font <size>      The font size used for legends and labels.
+  -f, --font <size>      The font size used for legends and labels.
                          The default is 8.
-  -m, --marker <size>    The size of the marker used with tag graphs.
+  -m, --marker <size>    The size of the marker used with tag graphs.
                          The default is 5.
-  -x, --xticks <num>     The maximum number of ticks on the x-axis.
+  -x, --xticks <num>     The maximum number of ticks on the x-axis.
                          The default is 15.
-n, --namemeta <name> The name of the metadata of the top-level test suite - where to get the name of the test round. By default, + where to get the name of the test round. By default,
                          names are got from the paths to input files.
   --argumentfile <path>  Reads arguments from the specified file.
   --verbose              The verbose output.
   --help                 Prints this help.
   --version              Prints the version information.

-Additionally, :code:`---` can be used to group options when creating multiple +Additionally, :code:`---` can be used to group options when creating multiple
 images at once.

-
 Description
 -----------

@@ -120,15 +118,12 @@
    path/to/*.xml
    ======================================

-
 Installation
 ------------

 :prog:`risto.py` itself does not need to be installed, simply running
-it from the command line is enough, but it has some preconditions. The
-most obvious one is Python, and versions 2.5 and 2.4 have been
-tested. Some Robot Framework internal modules are also needed, and
-thus Robot Framework version 1.8 or newer is required.
+it from the command line is enough. It has some preconditions, though,
+first ones being Robot Framework and Python.

 The Matplotlib tool is used for plotting graphs, and it needs to be
 installed separately. Matplotlib has its own preconditions, and at
@@ -139,26 +134,19 @@
 to use Matplotlib's own viewer for opening graphs without saving them
 to a file.

-:prog:`risto.py` reads statistics from XML output files using the
-ElementTree module. Python 2.5 and newer have this module in standard
-library, but for older versions it needs to be installed separately.
-
-Links to the needed software:
+Links to the needed software:

 Matplotlib
    http://matplotlib.sourceforge.net/
 NumPy
    http://numpy.scipy.org/
-ElementTree
-   http://effbot.org/zone/element-index.htm
-

 Screenshots
 -----------

 Default settings
 ~~~~~~~~~~~~~~~~
-
+
 The screenshot below uses some very simple example outputs, thus the lines
 are mainly straight. The default settings have been used otherwise,
 but the output has been saved into a file with the :opt:`--output
@@ -168,10 +156,9 @@
    :width: 800
    :height: 400

-
 Various settings
 ~~~~~~~~~~~~~~~~
-
+
 The example outputs used in this screenshot are the same as in the previous
 one, but now the following options have been specified::

@@ -180,11 +167,10 @@
 .. figure:: risto_another.png
    :width: 600
    :height: 250
-

 Using Matplotlib's viewer
 ~~~~~~~~~~~~~~~~~~~~~~~~~
-
+
 This time there are more input files and the image has been opened
 in Matplotlib's viewer (that is, the :opt:`--output` option has not been
 used). The options used to create this example are the ones below::
@@ -195,7 +181,6 @@
    :width: 820
    :height: 393

-
 More realistic examples
 ~~~~~~~~~~~~~~~~~~~~~~~

@@ -212,7 +197,7 @@
    --noall
    --tag phase-drt
    -nofailed
-   --output drt.png
+   --output drt.png
    ------------------
    path/*/output.xml

@@ -223,4 +208,3 @@
 .. figure:: risto_drt.png
    :width: 800
    :height: 400
-

==============================================================================
Revision: 4a885ca9ae43
Branch:   default
Author:   Pekka Klärck
Date:     Mon Jun 10 07:08:53 2013
Log:      risto.py: 2.8 compatibility
http://code.google.com/p/robotframework/source/detail?r=4a885ca9ae43

Modified:
 /tools/ristopy/risto.py

=======================================
--- /tools/ristopy/risto.py     Mon Jun 10 07:07:40 2013
+++ /tools/ristopy/risto.py     Mon Jun 10 07:08:53 2013
@@ -60,8 +60,7 @@
   -P --nopassed       Do not plot passed graphs.
   -F --nofailed       Do not plot failed graphs.
   -t --tag name *     Add graphs for these tags. Name can contain '*' and
-                      '?' as wildcards. 'AND' in the tag name is converted
-                      to ' & ', to make it easier to plot combined tags.
+                      '?' as wildcards.
   -o --output path    Path to the image file to create. If not given, the
                       image is opened into Matplotlib's image viewer.
   -i --title title    Title of the graph. Underscores in the given title
@@ -126,7 +125,7 @@
                       'Make sure you have Robot Framework installed.')


-__version__ = '1.0.1'
+__version__ = '1.0.2'


 class AllStatistics(object):
@@ -281,7 +280,7 @@
         # axes2 is used only for getting ytick labels also on right side
         self._axes2 = self._axes.twinx()
         self._axes2.set_xticklabels([], visible=False)
-        self._tags = self._get_tags(tags)
+        self._tags = tags or []
         self._critical = critical
         self._all = all
         self._totals = totals
@@ -302,11 +301,6 @@
         except ValueError:
raise DataError('Width, height, font and xticks must be numbers.')

-    def _get_tags(self, tags):
-        if tags is None:
-            return []
-        return [t.replace('AND',' & ') for t in tags]
-
     def set_axis(self, stats):
         slen = len(stats)
         self._indexes = range(slen)
@@ -345,7 +339,7 @@
             self._legends.append(Legend(label='all tests', **line))

     def tag(self, stats):
-        if utils.matches_any(stats[0].name, self._tags):
+        if utils.MultiMatcher(self._tags).match(stats[0].name):
             line = {'linestyle': '-', 'linewidth': 0.3}
             mark = {'marker': self._get_marker(),
                     'markersize': self._marker_size}

--

--- You received this message because you are subscribed to the Google Groups "robotframework-commit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to robotframework-commit+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to