ganesanb | 32d5542 | 2022-08-04 08:18:27 +0000 | [diff] [blame] | 1 | #!/usr/bin/env python3 -u |
| 2 | |
| 3 | r""" |
| 4 | Define methods to import platform specific files. |
| 5 | """ |
| 6 | |
George Keishing | e635ddc | 2022-12-08 07:38:02 -0600 | [diff] [blame] | 7 | import imp |
George Keishing | e635ddc | 2022-12-08 07:38:02 -0600 | [diff] [blame] | 8 | import importlib |
Patrick Williams | 20f3871 | 2022-12-08 06:18:26 -0600 | [diff] [blame] | 9 | import string |
| 10 | import sys |
| 11 | |
| 12 | from robot.libraries.BuiltIn import BuiltIn |
ganesanb | 32d5542 | 2022-08-04 08:18:27 +0000 | [diff] [blame] | 13 | |
| 14 | |
| 15 | def get_service_restart_policy_services(module_name): |
| 16 | r""" |
| 17 | Gets the service list that gives in the respective platform specific file. |
| 18 | """ |
| 19 | m = importlib.import_module(module_name) |
| 20 | service_restart_policy_services = dict.copy(m.SERVICES) |
| 21 | |
| 22 | return service_restart_policy_services |