bots: Add dependencies management.

Adds the file api/bots_api/provision.py that installs dependencies
for bots using pip. This file is also used by run.py when running
a bot. However, for testing, you need to separately provision the bots.
This commit is contained in:
Rohitt Vashishtha 2017-06-21 20:03:09 +05:30 committed by showell
parent bafbd3689b
commit 2645c97276
6 changed files with 90 additions and 9 deletions

View file

@ -53,6 +53,8 @@ if __name__ == '__main__':
suites = []
for bot_to_test in args.bots_to_test:
dep_path = os.path.join(bots_test_dir, bot_to_test, 'bot_dependencies')
sys.path.insert(0, dep_path)
try:
suites.append(loader.discover(start_dir = dir_join(bots_test_dir, bot_to_test),
top_level_dir = root_dir))