-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OSOE-815: Updating all dependencies, fixing SMTP tests, changing browser logging to BiDi, fixing analyzer violations #442
Open
Piedone
wants to merge
23
commits into
dev
Choose a base branch
from
issue/OSOE-815-combined
base: dev
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
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
…rowser log filter
# Conflicts: # Lombiq.Tests.UI/Attributes/InternetExplorerAttribute.cs
…o issue/OSOE-815-ui-testing-toolbox # Conflicts: # Lombiq.Tests.UI.Shortcuts/Lombiq.Tests.UI.Shortcuts.csproj # Lombiq.Tests.UI/Lombiq.Tests.UI.csproj
github-actions
bot
changed the title
Updating all dependencies, fixing SMTP tests, changing browser logging to BiDi, fixing analyzer violations
OSOE-815: Updating all dependencies, fixing SMTP tests, changing browser logging to BiDi, fixing analyzer violations
Dec 31, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
OSOE-815
To be included in the release notes:
Breaking changes in browser log management
The browser log, i.e. what you also see in the developer console, is useful to pinpoint unhandled JavaScript exceptions, network errors, and other client-side issues. This is what in Selenium can be accessed via
IWebDriver.Manage().Logs.GetLog(LogType.Browser)
. In the UI Testing Toolbox it was accessible via various other ways, and was also automatically asserted after every page load.In this release, how you can access the browser log, and what objects represent the log, changed. This was necessary because the previous version actually only supported Chrome and Edge, it just silently failed under other browsers (notably Firefox). With a new Selenium version, it now fails with an exception (that's why we actually noticed it).
To overcome this, all browsers now use the new Selenium BiDirectional API to access the logs.
What changed
UITestContext.HistoricBrowserLog
is now calledCumulativeBrowserLog
to better reflect that it stores all browser log entries since the start of the test. Instead of containingOpenQA.Selenium.LogEntry
objects, it containsOpenQA.Selenium.BiDi.Modules.Log.Entry
ones. These have a slightly different interface, but work much the same: Most possibly, you'll only need to change references toLogEntry.Message
toEntry.Text
, andLogEntry.Level
toEntry.Level
, which uses a different, but very similar, enum. For the same reason,ClearHistoricBrowserLog()
is now calledClearCumulativeBrowserLog()
but behaves the same.UITestContext.BrowserLogFilter
, to determine what gets logged in the first place. If you need to ignore expected log entries (since a non-empty log fails the test by default), we recommend adjusting the filter instead of the assertion. The samples contain examples of this.OrchardCoreUITestExecutorConfiguration.AssertBrowserLog
now works withOpenQA.Selenium.BiDi.Modules.Log.Entry
objects too, as do all related helpers.UITestContext.UpdateHistoricBrowserLogAsync()
was removed. It's not necessary anymore since the logs are now updated not explicitly, but with events, whenever a new entry is added.UITestContext.AssertCurrentBrowserLogAsync()
and theIWebDriver
extensionGetAndEmptyBrowserLog()
were also removed for the same reason.LogEntry.IsNotFoundLogEntry()
was removed since it can't apply toEntry
objects. Instead, check outUITestContext.CumulativeResponseLog
andUITestContext.ResponseLogFilter
. This new behavior is demonstrated in the samples.How to adapt