This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7.5 billion people | |
Let's assume that 10% of them are travelling = 750 million | |
Staying in hotels 10 nights per year | |
2.5 people per room | |
7.5 bn / 2.5 ~ 3 bn nights per year | |
On average, a hotel has 20 rooms | |
365 * 20 ~ 7500 stays | |
3 bn / 7500 = 400.000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private WebDriver logAppInfo(AppiumDriver<? extends WebElement> driver) { | |
String appPath = driver.getSessionDetail("app").toString(); | |
if (appPath != null) { | |
LOG.info("Application: {}", applicationInfoService.getAppInfo(appPath)); | |
} | |
return driver; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<pattern>%d{HH:mm:ss.SSS} %C{0}:%M:%L %msg %n</pattern> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static final Logger LOG = LoggerFactory.getLogger("loggerName"); | |
LOG.info("performing action " + actionName); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static final Logger LOG = LoggerFactory.getLogger(SomeJavaClass.class); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@CucumberOptions(plugin = "qa.justtestlah.log.CucumberOptionsBuilder") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private WebDriver logDeviceDetails(AppiumDriver<? extends WebElement> driver) { | |
LOG.info("Testing device: {}, manufacturer: {}, OS version: {}, screen size: {}", | |
driver.getSessionDetail("deviceName"), driver.getSessionDetail("deviceManufacturer"), | |
driver.getSessionDetail("platformVersion"), driver.getSessionDetail("deviceScreenSize")); | |
return driver; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<appender name="server" class="ch.qos.logback.core.ConsoleAppender"> | |
<encoder> | |
<pattern>%msg %n</pattern> | |
</encoder> | |
</appender> | |
<logger name="server" level="info" additivity="false"> | |
<appender-ref ref="server" /> | |
</logger> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package qa.justtestlah.log; | |
import java.text.DateFormat; | |
import java.text.SimpleDateFormat; | |
import java.util.Arrays; | |
import java.util.List; | |
import org.openqa.selenium.By; | |
import org.openqa.selenium.OutputType; | |
import org.openqa.selenium.WebDriver; | |
import org.openqa.selenium.WebElement; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- $[appInfo} will be replaced with the value of appInfo written to the log context --> | |
<pattern>${appInfo} %d{HH:mm:ss.SSS} %.-1level %C{0}:%M:%L %msg %n</pattern> |
NewerOlder