1313# License for the specific language governing permissions and limitations
1414# under the License.
1515
16- from __future__ import absolute_import
16+ import xml . etree . ElementTree as ET
1717from tests .modularinput .modularinput_testlib import unittest , xml_compare , data_open
1818from splunklib .modularinput .scheme import Scheme
1919from splunklib .modularinput .argument import Argument
2020
21- try :
22- import xml .etree .cElementTree as ET
23- except ImportError :
24- import xml .etree .ElementTree as ET
2521
2622class SchemeTest (unittest .TestCase ):
2723 def test_generate_xml_from_scheme_with_default_values (self ):
@@ -40,7 +36,7 @@ def test_generate_xml_from_scheme(self):
4036 some arguments added matches what we expect."""
4137
4238 scheme = Scheme ("abcd" )
43- scheme .description = u "쎼 and 쎶 and <&> für"
39+ scheme .description = "쎼 and 쎶 and <&> für"
4440 scheme .streaming_mode = Scheme .streaming_mode_simple
4541 scheme .use_external_validation = "false"
4642 scheme .use_single_instance = "true"
@@ -50,7 +46,7 @@ def test_generate_xml_from_scheme(self):
5046
5147 arg2 = Argument (
5248 name = "arg2" ,
53- description = u "쎼 and 쎶 and <&> für" ,
49+ description = "쎼 and 쎶 and <&> für" ,
5450 validation = "is_pos_int('some_name')" ,
5551 data_type = Argument .data_type_number ,
5652 required_on_edit = True ,
@@ -69,7 +65,7 @@ def test_generate_xml_from_scheme_with_arg_title(self):
6965 some arguments added matches what we expect. Also sets the title on an argument."""
7066
7167 scheme = Scheme ("abcd" )
72- scheme .description = u "쎼 and 쎶 and <&> für"
68+ scheme .description = "쎼 and 쎶 and <&> für"
7369 scheme .streaming_mode = Scheme .streaming_mode_simple
7470 scheme .use_external_validation = "false"
7571 scheme .use_single_instance = "true"
@@ -79,7 +75,7 @@ def test_generate_xml_from_scheme_with_arg_title(self):
7975
8076 arg2 = Argument (
8177 name = "arg2" ,
82- description = u "쎼 and 쎶 and <&> für" ,
78+ description = "쎼 and 쎶 and <&> für" ,
8379 validation = "is_pos_int('some_name')" ,
8480 data_type = Argument .data_type_number ,
8581 required_on_edit = True ,
@@ -113,7 +109,7 @@ def test_generate_xml_from_argument(self):
113109
114110 argument = Argument (
115111 name = "some_name" ,
116- description = u "쎼 and 쎶 and <&> für" ,
112+ description = "쎼 and 쎶 and <&> für" ,
117113 validation = "is_pos_int('some_name')" ,
118114 data_type = Argument .data_type_boolean ,
119115 required_on_edit = "true" ,
0 commit comments