diff options
| author | mra (Open ERP) <mra@tinyerp.com> | 2009-09-29 17:50:27 +0530 |
|---|---|---|
| committer | mra (Open ERP) <mra@tinyerp.com> | 2009-09-29 17:50:27 +0530 |
| commit | 34645503b72e0e7196f98f0ebca0902009afddba (patch) | |
| tree | 16e556462c362e3a75aa13a30282d1dd7ee60e5c /addons/base_module_quality/structure_test | |
| parent | 6898b2230a2eb1a837dc0c349d0cc4f332344e49 (diff) | |
[IMP] base_module_quality: styles on different tests
bzr revid: mra@tinyerp.com-20090929122027-8e01uw61dwax00h3
Diffstat (limited to 'addons/base_module_quality/structure_test')
| -rw-r--r-- | addons/base_module_quality/structure_test/structure_test.py | 26 |
1 files changed, 5 insertions, 21 deletions
diff --git a/addons/base_module_quality/structure_test/structure_test.py b/addons/base_module_quality/structure_test/structure_test.py index 5c43d3a0e10..00489ed9a40 100644 --- a/addons/base_module_quality/structure_test/structure_test.py +++ b/addons/base_module_quality/structure_test/structure_test.py @@ -23,6 +23,7 @@ import os from tools.translate import _ from base_module_quality import base_module_quality +import pooler class quality_test(base_module_quality.abstract_quality_check): @@ -135,7 +136,6 @@ This test checks if the module satisfy tiny structure self.module_score += final_score self.score = self.module_score / (self.count) self.result = self.get_result({ module_name: [module_name, int(self.score*100)]}) -# self.result_details += self.get_result_details(self.result_dict) return None def run_test(self, cr, uid, module_path): @@ -170,28 +170,12 @@ This test checks if the module satisfy tiny structure return score def get_result_details(self, dict_struct): - str_html = '''<html><head> - <style> - .bstyle - { - border-width:2px; - border-style:dashed; - border-color: gray; - } - .btstyle - { - border-width:2px; - border-style:solid; - border-color: gray; - } - } - </style></head><body><table class="bstyle">''' - header = ('<tr><th class="btstyle">%s</th><th class="btstyle">%s</th></tr>', [_('File Name'), _('Feedback about structure of module')]) + str_html = '''<html><head>%s</head><body><table class="tablestyle">'''%(self.get_style()) + header = ('<tr><th class="tdatastyle">%s</th><th class="tdatastyle">%s</th></tr>', [_('File Name'), _('Feedback about structure of module')]) if not self.error: res = str_html + self.format_html_table(header, data_list=dict_struct) + '</table></body></html>' - res = res.replace('''<td''', '''<td class="btstyle" ''') + res = res.replace('''<td''', '''<td class="tdatastyle" ''') return res return "" -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: - +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
\ No newline at end of file |
