diff options
author | Chris Larson <chris_larson@mentor.com> | 2010-04-09 11:49:36 -0700 |
---|---|---|
committer | Richard Purdie <rpurdie@linux.intel.com> | 2010-07-02 15:41:32 +0100 |
commit | bbf83fd988ca3cf9dae7d2b542a11a7c942b1702 (patch) | |
tree | af91902ea2f1d9132b89a246ac5bb053e956d6bf /bitbake/lib/bb/utils.py | |
parent | 8306ba50db13eb3adcc0161e120c53c3f7aefe7b (diff) | |
download | poky-bbf83fd988ca3cf9dae7d2b542a11a7c942b1702.tar.gz |
Drop doctest, as we aren't utilizing it
We should add back in some proper unit testing. Doctest is rather limited,
and we haven't actually made use of it since the original implementation of
the datastore when the project started, as far as I'm aware.
(Bitbake rev: 3a11c2807972bbbddffde2fa67fc380d159da467)
Signed-off-by: Chris Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'bitbake/lib/bb/utils.py')
-rw-r--r-- | bitbake/lib/bb/utils.py | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/bitbake/lib/bb/utils.py b/bitbake/lib/bb/utils.py index eee97276a2..5015ee440a 100644 --- a/bitbake/lib/bb/utils.py +++ b/bitbake/lib/bb/utils.py | |||
@@ -97,14 +97,7 @@ _package_ends_ = ["pre", "p", "alpha", "beta", "rc", "cvs", "bk", "HEAD" ] | |||
97 | 97 | ||
98 | def relparse(myver): | 98 | def relparse(myver): |
99 | """Parses the last elements of a version number into a triplet, that can | 99 | """Parses the last elements of a version number into a triplet, that can |
100 | later be compared: | 100 | later be compared. |
101 | |||
102 | >>> relparse('1.2_pre3') | ||
103 | [1.2, -2, 3.0] | ||
104 | >>> relparse('1.2b') | ||
105 | [1.2, 98, 0] | ||
106 | >>> relparse('1.2') | ||
107 | [1.2, 0, 0] | ||
108 | """ | 101 | """ |
109 | 102 | ||
110 | number = 0 | 103 | number = 0 |
@@ -150,17 +143,6 @@ __vercmp_cache__ = {} | |||
150 | def vercmp_string(val1,val2): | 143 | def vercmp_string(val1,val2): |
151 | """This takes two version strings and returns an integer to tell you whether | 144 | """This takes two version strings and returns an integer to tell you whether |
152 | the versions are the same, val1>val2 or val2>val1. | 145 | the versions are the same, val1>val2 or val2>val1. |
153 | |||
154 | >>> vercmp('1', '2') | ||
155 | -1.0 | ||
156 | >>> vercmp('2', '1') | ||
157 | 1.0 | ||
158 | >>> vercmp('1', '1.0') | ||
159 | 0 | ||
160 | >>> vercmp('1', '1.1') | ||
161 | -1.0 | ||
162 | >>> vercmp('1.1', '1_p2') | ||
163 | 1.0 | ||
164 | """ | 146 | """ |
165 | 147 | ||
166 | # quick short-circuit | 148 | # quick short-circuit |