Source code for apama.basetest
#!/usr/bin/env python3
# Copyright (c) 2018 Software AG, Darmstadt, Germany and/or Software AG USA Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.
# Use, reproduction, transfer, publication or disclosure is prohibited except as specifically provided for in your License Agreement with Software AG
from pysys.basetest import BaseTest
from os import path
[docs]class ApamaBaseTest(BaseTest):
"""
A custom PySys basetest for Apama tests.
"""
[docs] def __init__(self, descriptor, outsubdir, runner):
super(ApamaBaseTest, self).__init__(descriptor, outsubdir, runner)
[docs] def getDefaultFileEncoding(self, file, **xargs):
filename, file_extension = path.splitext(file)
if file_extension in ['xml', 'yaml', 'json', 'log']:
return 'utf-8'
else:
return None