From 3cc479535865e3e1948ce8812f12e1d0a34031c8 Mon Sep 17 00:00:00 2001 From: wking Date: Thu, 25 Jun 2009 17:10:57 -0400 Subject: [PATCH] Fixed libbe.rcs.RCS.installed to handle missing backend binary. This makes all the failed tests understandable, since they all crash with strings like: AssertionError: Arch RCS not found Which makes more sense than spitting out the raw CommandError. It also means that installed_rcs() actually works now ;). --- libbe/rcs.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libbe/rcs.py b/libbe/rcs.py index c0b92e7..3428ce0 100644 --- a/libbe/rcs.py +++ b/libbe/rcs.py @@ -40,8 +40,7 @@ def _get_matching_rcs(matchfn): rcs = module.new() if matchfn(rcs) == True: return rcs - else: - del(rcs) + del(rcs) return RCS() def rcs_by_name(rcs_name): @@ -205,7 +204,8 @@ class RCS(object): except OSError, e: if e.errno == errno.ENOENT: return False - raise e + except CommandError: + return False def detect(self, path="."): """ Detect whether a directory is revision controlled with this RCS. -- 2.26.2