tests/hghave.py
changeset 1111 df702ad9b314
parent 1105 9b2932ca75fd
child 1133 82f74372516e
equal deleted inserted replaced
1103:9459951761fb 1111:df702ad9b314
   237         return True
   237         return True
   238     except ImportError:
   238     except ImportError:
   239         return False
   239         return False
   240 
   240 
   241 def has_outer_repo():
   241 def has_outer_repo():
   242     return matchoutput('hg root 2>&1', r'')
   242     # failing for other reasons than 'no repo' imply that there is a repo
       
   243     return not matchoutput('hg root 2>&1',
       
   244                            r'abort: no repository found', True)
   243 
   245 
   244 def has_ssl():
   246 def has_ssl():
   245     try:
   247     try:
   246         import ssl
   248         import ssl
   247         import OpenSSL
   249         import OpenSSL