Changeset 139
- Timestamp:
- 08/09/06 08:48:17 (2 years ago)
- Files:
-
- branches/mk/cheesecake/cheesecake_index.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/mk/cheesecake/cheesecake_index.py
r135 r139 924 924 self.value = 0 925 925 if percent > 0.75: 926 self.add_info("%.2f%% formatted docstrings found, which is > 75%% and is worth 30p." % (percent*100)) 926 927 self.value = 30 927 928 elif percent > 0.50: 929 self.add_info("%.2f%% formatted docstrings found, which is > 50%% and is worth 20p." % (percent*100)) 928 930 self.value = 20 929 931 elif percent > 0.25: 932 self.add_info("%.2f%% formatted docstrings found, which is > 25%% and is worth 10p." % (percent*100)) 930 933 self.value = 10 934 else: 935 self.add_info("%.2f%% formatted docstrings found, which is < 25%%, no points given." % (percent*100)) 931 936 932 937 self.details = "found %d/%d=%.2f%% objects with formatted docstrings" %\ … … 1097 1102 pylint_score = 0 1098 1103 self.value = int(ceil(pylint_score/10.0 * self.max_value)) 1104 1105 self.add_info("Score is %.2f/10, which is %d%% of maximum %d points = %d." % 1106 (pylint_score, int(pylint_score*10), self.max_value, self.value)) 1099 1107 1100 1108 return self.value
