Use warnings to warn user

This commit is contained in:
Daniel A. Wozniak 2018-04-19 08:26:50 -07:00
parent 144c68e214
commit cadd759727
No known key found for this signature in database
GPG key ID: 166B9D2C06C82D61

View file

@ -10,6 +10,7 @@ from __future__ import absolute_import, print_function
import os
import sys
import time
import warnings
TESTS_DIR = os.path.dirname(os.path.normpath(os.path.abspath(__file__)))
if os.name == 'nt':
@ -481,7 +482,7 @@ class SaltTestsuiteParser(SaltCoverageTestingParser):
not is_admin,
not self.options.run_destructive)) \
and self._check_enabled_suites(include_unit=True):
log.warn("Test suite not running with elevated priviledges")
warnings.warn("Test suite not running with elevated priviledges")
else:
is_admin = os.geteuid() == 0