VirtualBox

Changeset 65503 in vbox for trunk/src/VBox/ValidationKit


Ignore:
Timestamp:
Jan 28, 2017 10:45:17 PM (8 years ago)
Author:
vboxsync
Message:

wuireport.py: try decimal point on success graph when going below 10%.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ValidationKit/testmanager/webui/wuireport.py

    r65500 r65503  
    129129
    130130    @staticmethod
    131     def fmtPctWithTotal(cHits, cTotal):
     131    def fmtPctWithHits(cHits, cTotal):
    132132        """
    133133        Formats a percent number with total in parentheses.
    134134        Returns a string.
    135135        """
    136         return '%s (%s)' % (WuiReportBase.fmtPct(cHits, cTotal), cTotal);
     136        return '%s (%s)' % (WuiReportBase.fmtPct(cHits, cTotal), cHits);
    137137
    138138    @staticmethod
     
    170170                                dStatuses[ReportModelBase.ksTestStatus_Skipped] * 100 / cTotal,
    171171                                dStatuses[ReportModelBase.ksTestStatus_Failure] * 100 / cTotal, ],
    172                               [ self.fmtPctWithTotal(dStatuses[ReportModelBase.ksTestStatus_Success], cTotal),
    173                                 self.fmtPctWithTotal(dStatuses[ReportModelBase.ksTestStatus_Skipped], cTotal),
    174                                 self.fmtPctWithTotal(dStatuses[ReportModelBase.ksTestStatus_Failure], cTotal), ]);
     172                              [ self.fmtPctWithHits(dStatuses[ReportModelBase.ksTestStatus_Success], cTotal),
     173                                self.fmtPctWithHits(dStatuses[ReportModelBase.ksTestStatus_Skipped], cTotal),
     174                                self.fmtPctWithHits(dStatuses[ReportModelBase.ksTestStatus_Failure], cTotal), ]);
    175175            else:
    176176                oTable.addRow(sPeriod, [ 0, 0, 0 ], [ '0%', '0%', '0%' ]);
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette