Package com.github.invictum.reportportal
Class LogStorage
java.lang.Object
com.github.invictum.reportportal.LogStorage
Central storage for collected logs provided by Selenium
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclean()Clears all logs related to current threadvoidcollect(org.openqa.selenium.logging.Logs seleniumLogs) CollectsWebDriverlogs if available and stores its to internal storage If error is occurred during log collection all future calls will be cancelledquery(Predicate<EnhancedLogEntry> predicate) Returns logs that meets defined condition and removes them from storage.
-
Constructor Details
-
LogStorage
public LogStorage()
-
-
Method Details
-
collect
public void collect(org.openqa.selenium.logging.Logs seleniumLogs) CollectsWebDriverlogs if available and stores its to internal storage If error is occurred during log collection all future calls will be cancelled- Parameters:
seleniumLogs- to collect from
-
clean
public void clean()Clears all logs related to current thread -
query
Returns logs that meets defined condition and removes them from storage. Logs could be queried only once- Parameters:
predicate- condition to use to find logs- Returns:
- a list of queried logs
-