File tree Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Original file line number Diff line number Diff line change 66except : # Python 3
77 from urllib .parse import urljoin
88import time
9- try :
10- FileNotFoundError # Python 3
11- except NameError :
12- FileNotFoundError = IOError # Python 2
139
1410import requests
1511
@@ -48,12 +44,14 @@ def load_conf(filename):
4844 "placeholder": null
4945 }
5046 """
51- try :
47+ conf = {}
48+ if os .path .exists (filename ):
5249 with open (filename ) as f :
5350 conf = json .load (f )
54- except FileNotFoundError :
55- raise unittest .SkipTest (
56- "Unable to open/read JSON configuration %s" % filename )
51+ else :
52+ # Do not raise unittest.SkipTest(...) here,
53+ # because it would still be considered as Test Error in Python 2
54+ logger .warning ("Unable to locate JSON configuration %s" % filename )
5755 openid_configuration = {}
5856 if "oidp" in conf :
5957 try :
You can’t perform that action at this time.
0 commit comments