summaryrefslogtreecommitdiffstats
path: root/tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py
diff options
context:
space:
mode:
authorsridharkn <sridhar@linux.com>2016-04-11 19:32:44 +0530
committerMaryam Tahhan <maryam.tahhan@intel.com>2016-04-12 11:50:41 +0000
commita8e1c6a42bd55a70268ecefc44f81870c539848b (patch)
tree3bd9543151dc1802024d8c7eb762c3a191871b7e /tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py
parent01bff4c5650f4cfb992276278d170a21c91431c3 (diff)
pkt_gen: Testcenter traffic generation using STC-REST API -Import Issue.
The import of stcrestclient in moved down to avoid execution errors. Change-Id: Ib9b64f62400c20a031f0ffcd3410582741cf1644 JIRA: VSPERF-237
Diffstat (limited to 'tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py')
-rw-r--r--tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py b/tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py
index 13f68fb7..428240a1 100644
--- a/tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py
+++ b/tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py
@@ -23,8 +23,6 @@ import argparse
import logging
import os
-# Load Spirent REST Library
-from stcrestclient import stchttp
logger = logging.getLogger(__name__)
@@ -281,6 +279,9 @@ def main():
user_name = args.test_user_name
try:
+ # Load Spirent REST Library
+ from stcrestclient import stchttp
+
stc = stchttp.StcHttp(args.lab_server_addr)
session_id = stc.new_session(user_name, session_name)
stc.join_session(session_id)