Skip to content

Commit cf0581c

Browse files
author
Shakeel Mohamed
committed
Pythonic naming convention fix
1 parent 2e5a09c commit cf0581c

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

splunklib/modularinput/scheme.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ def __init__(self, title):
3737
self.title = title
3838
self.description = None
3939
self.use_external_validation = True
40-
self.useSingleInstance = False
41-
self.streamingMode = Scheme.streaming_mode_xml
40+
self.use_single_instance = False
41+
self.streaming_mode = Scheme.streaming_mode_xml
4242

4343
# list of Argument objects, each to be represented by an <arg> tag
4444
self.arguments = []
@@ -65,8 +65,8 @@ def to_XML(self):
6565

6666
# add other subelements
6767
ET.SubElement(root, "use_external_validation").text = str(self.use_external_validation).lower()
68-
ET.SubElement(root, "use_single_instance").text = str(self.useSingleInstance).lower()
69-
ET.SubElement(root, "streaming_mode").text = self.streamingMode.lower()
68+
ET.SubElement(root, "use_single_instance").text = str(self.use_single_instance).lower()
69+
ET.SubElement(root, "streaming_mode").text = self.streaming_mode.lower()
7070

7171
endpoint = ET.SubElement(root, "endpoint")
7272

tests/modularinput/test_scheme.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,9 @@ def test_generate_xml_from_scheme(self):
4040

4141
scheme = Scheme("abcd")
4242
scheme.description = u"쎼 and 쎶 and <&> für"
43-
scheme.streamingMode = Scheme.streaming_mode_simple
43+
scheme.streaming_mode = Scheme.streaming_mode_simple
4444
scheme.use_external_validation = "false"
45-
scheme.useSingleInstance = "true"
45+
scheme.use_single_instance = "true"
4646

4747
arg1 = Argument(name="arg1")
4848
scheme.add_argument(arg1)

0 commit comments

Comments
 (0)