diff options
author | Sebastian Pipping <sebastian@pipping.org> | 2010-01-04 05:36:34 +0100 |
---|---|---|
committer | Sebastian Pipping <sebastian@pipping.org> | 2010-01-04 05:36:34 +0100 |
commit | 836dea135b73c2b0e802888702c6b67c86f2bea4 (patch) | |
tree | 2dde4565291ae18112053c66210beb936a9ac2d1 /layman/overlays/cvs.py | |
parent | 4cfd62c88c855c90f56db1a60ef2e438b13ca3d6 (diff) | |
download | layman-836dea135b73c2b0e802888702c6b67c86f2bea4.tar.gz layman-836dea135b73c2b0e802888702c6b67c86f2bea4.tar.bz2 layman-836dea135b73c2b0e802888702c6b67c86f2bea4.zip |
Introduce equality and inequality tests
Diffstat (limited to 'layman/overlays/cvs.py')
-rw-r--r-- | layman/overlays/cvs.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/layman/overlays/cvs.py b/layman/overlays/cvs.py index a4ff74d..a9c4f0f 100644 --- a/layman/overlays/cvs.py +++ b/layman/overlays/cvs.py @@ -48,6 +48,14 @@ class CvsOverlay(Overlay): else: self.subpath = '' + def __eq__(self, other): + res = super(CvsOverlay, self).__eq__(other) \ + and self.subpath == other.subpath + return res + + def __ne__(self, other): + return not self.__eq__(other) + def add(self, base, quiet = False): '''Add overlay.''' |