I want to set the appium log level to debug when running tests from jenkins via KRE. I know you can set it in the KS preferences in the UI, for local execution, but I do not know how when using the runtime.
1 Like
I would second this a lot, or jenkins runs have huge console file sizes because all of the appium logging.
After looking into this I figured out how to do it, before starting the application (before calling startApplication), call this:
RunConfiguration.getDriverSystemProperties(StringConstants.CONF_PROPERTY_MOBILE_DRIVER).put(StringConstants.CONF_APPIUM_LOG_LEVEL, GlobalVariable.LogLevel)
Then you could set a global variable in a profile, that is the log level you want to set, so then you can override that global variable in the KRE commandline:
-g_LogLevel="warn"
Hope this helps!
Thank you Nathaniel! looks like a good solution I will try it.
-K