1+ from __future__ import print_function
12import sys
23import os
34import os .path as op
1819
1920
2021def setup_environment ():
21- print 'Setup solnlib demo environment...'
22- print 'Copying %s to %s' % (source_dir , target_dir )
22+ print ( 'Setup solnlib demo environment...' )
23+ print ( 'Copying %s to %s' % (source_dir , target_dir ) )
2324 shutil .copytree (source_dir , target_dir )
2425 shutil .copytree (solnlib_lib_dir ,
2526 solnlib_lib_target_dir )
2627 os .system (splunk_bin + ' start' )
2728
2829
2930def teardown_environment ():
30- print 'Teardown solnlib demo environment...'
31+ print ( 'Teardown solnlib demo environment...' )
3132 os .system (splunk_bin + ' stop' )
32- print 'Removing %s' % target_dir
33+ print ( 'Removing %s' % target_dir )
3334 if op .exists (target_dir ):
3435 shutil .rmtree (target_dir )
3536
@@ -47,31 +48,31 @@ def run_test():
4748 import test_hec_event_writer
4849 import test_time_parser
4950
50- print 'check splunk environment...'
51+ print ( 'check splunk environment...' )
5152 test_splunkenv .test_splunkenv ()
52- print 'check splunk server info...'
53+ print ( 'check splunk server info...' )
5354 test_server_info .test_server_info ()
54- print 'test kvstore...'
55+ print ( 'test kvstore...' )
5556 test_kvstore .test_kvstore ()
56- print 'test metadata reader...'
57+ print ( 'test metadata reader...' )
5758 test_metadata .test_metadata_reader ()
58- print 'test acl manager...'
59+ print ( 'test acl manager...' )
5960 test_acl .test_acl_manager ()
60- print 'test credential manager...'
61+ print ( 'test credential manager...' )
6162 test_credentials .test_credential_manager ()
62- print 'test conf manager...'
63+ print ( 'test conf manager...' )
6364 test_conf_manager .test_conf_manager ()
64- print 'test user access...'
65+ print ( 'test user access...' )
6566 test_user_access .test_user_access ()
66- print 'test hec config...'
67+ print ( 'test hec config...' )
6768 test_hec_config .test_hec_config ()
68- print 'test hec eventwriter...'
69+ print ( 'test hec eventwriter...' )
6970 test_hec_event_writer .test_hec_event_writer ()
70- print 'test time parser...'
71+ print ( 'test time parser...' )
7172 test_time_parser .test_time_parser ()
7273
7374if __name__ == '__main__' :
7475 teardown_environment ()
7576 setup_environment ()
7677 run_test ()
77- print 'Run tests success.'
78+ print ( 'Run tests success.' )
0 commit comments