Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ezh committed Feb 11, 2020
1 parent 2672def commit 46d5c7d
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 12 deletions.
3 changes: 2 additions & 1 deletion cloudselect/cloud.json.dist
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@
"bastion": "cloudselect.pathfinder.bastion"
},
"report": {
"json": "cloudselect.report.json"
"json": "cloudselect.report.json",
"json_pp": "cloudselect.report.json_pp"
}
}
}
18 changes: 8 additions & 10 deletions cloudselect/selector.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,13 +152,11 @@ def select(self):
if args.edit is None or args.edit:
if args.edit is None:
configuration = os.path.join(configpath, "{}".format(extension))
self.edit(configuration)
else:
profile = os.path.join(configpath, "{}.{}".format(args.edit, extension))
self.edit(profile)
elif args.reporter is None:
self.reporter_list()
elif not args.profile:
self.profile_list()
else:
self.profile_process()
return self.edit(configuration)
profile = os.path.join(configpath, "{}.{}".format(args.edit, extension))
return self.edit(profile)
if args.reporter is None:
return self.reporter_list()
if not args.profile:
return self.profile_list()
return self.profile_process()
5 changes: 4 additions & 1 deletion test/test_cloudselect.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,10 @@ def test_cli_configuration_read():
},
"group": {"simple": "cloudselect.group.simple"},
"pathfinder": {"bastion": "cloudselect.pathfinder.bastion"},
"report": {"json": "cloudselect.report.json"},
"report": {
"json": "cloudselect.report.json",
"json_pp": "cloudselect.report.json_pp",
},
},
}
cloud = CloudSelect()
Expand Down

0 comments on commit 46d5c7d

Please sign in to comment.