Skip to content

Commit d4a4396

Browse files
committed
Try our favourite hack to fix tests
1 parent c65ea48 commit d4a4396

6 files changed

Lines changed: 28 additions & 1 deletion

File tree

tests/system/test_apps/cre_app/bin/execute.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
1-
import splunk.rest
21
import json
2+
import os
3+
import sys
4+
5+
sys.path.insert(0, "/splunklib-deps")
6+
sys.path.insert(0, os.path.join(os.path.dirname(__file__), "lib"))
7+
8+
9+
import splunk.rest
310

411

512
class Handler(splunk.rest.BaseRestHandler):

tests/system/test_apps/eventing_app/bin/eventingcsc.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,12 @@
1212
# License for the specific language governing permissions and limitations
1313
# under the License.
1414

15+
import os
1516
import sys
1617

18+
sys.path.insert(0, "/splunklib-deps")
19+
sys.path.insert(0, os.path.join(os.path.dirname(__file__), "lib"))
20+
1721
from splunklib.searchcommands import (
1822
Configuration,
1923
EventingCommand,

tests/system/test_apps/generating_app/bin/generatingcsc.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,13 @@
1212
# License for the specific language governing permissions and limitations
1313
# under the License.
1414

15+
import os
1516
import sys
1617
import time
1718

19+
sys.path.insert(0, "/splunklib-deps")
20+
sys.path.insert(0, os.path.join(os.path.dirname(__file__), "lib"))
21+
1822
from splunklib.searchcommands import (
1923
Configuration,
2024
GeneratingCommand,

tests/system/test_apps/modularinput_app/bin/modularinput.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,13 @@
1212
# License for the specific language governing permissions and limitations
1313
# under the License.
1414

15+
import os
1516
import sys
1617
from urllib import parse
1718

19+
sys.path.insert(0, "/splunklib-deps")
20+
sys.path.insert(0, os.path.join(os.path.dirname(__file__), "lib"))
21+
1822
from splunklib.modularinput import Argument, Event, Scheme, Script
1923

2024

tests/system/test_apps/reporting_app/bin/reportingcsc.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,12 @@
1212
# License for the specific language governing permissions and limitations
1313
# under the License.
1414

15+
import os
1516
import sys
1617

18+
sys.path.insert(0, "/splunklib-deps")
19+
sys.path.insert(0, os.path.join(os.path.dirname(__file__), "lib"))
20+
1721
from splunklib.searchcommands import (
1822
Configuration,
1923
Option,

tests/system/test_apps/streaming_app/bin/streamingcsc.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,12 @@
1212
# License for the specific language governing permissions and limitations
1313
# under the License.
1414

15+
import os
1516
import sys
1617

18+
sys.path.insert(0, "/splunklib-deps")
19+
sys.path.insert(0, os.path.join(os.path.dirname(__file__), "lib"))
20+
1721
from splunklib.searchcommands import (
1822
Configuration,
1923
StreamingCommand,

0 commit comments

Comments
 (0)