Exemple #1
0
def debug(status=True):
	global DEBUG
	DEBUG = status
	if DEBUG:
		setShowActions(True)
	else:
		setShowActions(False)
# Add image libraries (searched in order)
addImagePath(Config.imageBaseline + slash + "os" + slash + str(Env.getOS()).lower() + slash + str(Env.getOSVersion(True)).lower() + slash + Config.language )
addImagePath(Config.imageBaseline + slash + "os" + slash + str(Env.getOS()).lower() + slash + str(Env.getOSVersion(True)).lower())

addImagePath(Config.imageBaseline + slash + "os" + slash + str(Env.getOS()).lower() + slash + Config.language )
addImagePath(Config.imageBaseline + slash + "os" + slash + str(Env.getOS()).lower())

addImagePath(Config.imageBaseline + slash + Config.language )
addImagePath(Config.imageBaseline)

logger.trace("Image search path: %s" % getImagePath())

# Sikuli shows a visual effect (a blinking double lined red circle) on the spot where the action
if Config.debugPlaybackMode: 
    setShowActions(True)

setAutoWaitTimeout(Config.waitTime)
Config.screen.setAutoWaitTimeout(Config.waitTime)
Region.timeout = Config.waitTime

# Set the logging level
if os.environ.get('LOGLEVEL') == 'INFO':
    EntityLoggerProxy.getLogger().setLevel(INFO)
elif os.environ.get('LOGLEVEL') == 'DEBUG':
    EntityLoggerProxy.getLogger().setLevel(DEBUG)
elif os.environ.get('LOGLEVEL') == 'TRACE':
    EntityLoggerProxy.getLogger().setLevel(TRACE)
else:
    EntityLoggerProxy.getLogger().setLevel(INFO)
    
Exemple #3
0
             str(Env.getOS()).lower() + slash +
             str(Env.getOSVersion(True)).lower())

addImagePath(Config.imageBaseline + slash + "os" + slash +
             str(Env.getOS()).lower() + slash + Config.language)
addImagePath(Config.imageBaseline + slash + "os" + slash +
             str(Env.getOS()).lower())

addImagePath(Config.imageBaseline + slash + Config.language)
addImagePath(Config.imageBaseline)

logger.trace("Image search path: %s" % getImagePath())

# Sikuli shows a visual effect (a blinking double lined red circle) on the spot where the action
if Config.debugPlaybackMode:
    setShowActions(True)

setAutoWaitTimeout(Config.waitTime)
Config.screen.setAutoWaitTimeout(Config.waitTime)
Region.timeout = Config.waitTime

# Set the logging level
if os.environ.get('LOGLEVEL') == 'INFO':
    EntityLoggerProxy.getLogger().setLevel(INFO)
elif os.environ.get('LOGLEVEL') == 'DEBUG':
    EntityLoggerProxy.getLogger().setLevel(DEBUG)
elif os.environ.get('LOGLEVEL') == 'TRACE':
    EntityLoggerProxy.getLogger().setLevel(TRACE)
else:
    EntityLoggerProxy.getLogger().setLevel(INFO)