summaryrefslogtreecommitdiffstats
path: root/vstf/vstf/agent/perf/affctl.py
diff options
context:
space:
mode:
Diffstat (limited to 'vstf/vstf/agent/perf/affctl.py')
-rwxr-xr-xvstf/vstf/agent/perf/affctl.py18
1 files changed, 18 insertions, 0 deletions
diff --git a/vstf/vstf/agent/perf/affctl.py b/vstf/vstf/agent/perf/affctl.py
new file mode 100755
index 00000000..e9b96924
--- /dev/null
+++ b/vstf/vstf/agent/perf/affctl.py
@@ -0,0 +1,18 @@
+#!/usr/bin/python
+# -*- coding: utf8 -*-
+# author: wly
+# date: 2015/11/26
+# see license for license details
+
+from vstf.common.utils import check_call, call, check_output
+
+
+def affctl_load(policy):
+ cmd = "affctl load %s" % policy
+ return check_call(cmd, shell=True)
+
+
+def affctl_list():
+ cmd = "affctl list"
+ return check_output(cmd, shell=True)
+