-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[dotnet] Simplify and add examples for bidi network intercepring #1467
[dotnet] Simplify and add examples for bidi network intercepring #1467
Conversation
✅ Deploy Preview for selenium-dev ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
We need to check that failing test... |
I don't mind. |
We were getting the known location of the driver from PATH, but we can't do that any more. The goal is to be able to show that it will use a driver passed in. Maybe we download a different driver to cache and pass it in? |
I reproduced it locally: var service = ChromeDriverService.CreateDefaultService();
service.DriverServicePath = "C:\\Temp";
driver = new ChromeDriver(service); And getting:
|
Do you think changes in this PR caused errors? I believe no. I am not planning to fix failed tests in scope of this PR. |
f84d8f8
to
8f4facc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please replace all the code in the md files with:
{{< gh-codeblock path="examples/dotnet/SeleniumDocs/ChromeDevTools/NetworkInterceptor.cs#L13-L24" >}}
Because all the other tabs are using automatic code formatting, we need to put text=true
in the tabpane and code=true
in the CSharp tab.
I need to (soon) go through and update all the marking so that we know what needs to be fixed.
Interesting, I created PR to add examples for BiDi network intercepting. BUT .net binding doesn't implement any BiDi protocol. @titusfortner Do you still think is it valid example? |
We need to make a distinction here when we use the term "BiDi" in Selenium. There are features that are bidirectional in nature, and can be referred to as "BiDi" features. Network interception is one of these types of features. Note very carefully that use of the term "BiDi" in this context has no bearing whatsoever on what protocol is used to implement that feature. Ideally, it will one day be implemented using the WebDriver BiDi protocol; currently it's still a "BiDi" feature, but implemented using CDP. So, in this context, the .NET bindings most certainly do implement a "BiDi protocol," it's just CDP, not WebDriver BiDi. |
Thank you @jimevans , then show must go on. |
But why java examples are not done in this way? Java examples are "hardcoded", I would like to do the same. For instance I don't want to include And, what if I change C# source code like adding new lines in the code, will it update examples accordingly? |
Because the Java examples are wrong. When lines of code are updated in the examples, we need to make sure that the md files all get updated as necessary. |
Also, this guarantees that code examples are working. |
We need to keep text=true on those tabs. Docsy had it right in their previous version when they had code be opt-in instead of text as opt-in. Without text=true, the website treats whatever you write as code |
247818e
to
e83ca6b
Compare
I've been futzing with the docs and moving things around. I just moved the examples to the "correct" location (the test file locations are supposed to match the page locations, but the BiDi/CDP examples haven't been following that convention. Since you created a 3rd test, I added a new section in docs to include a reference to it. Hmm, I think I misspelled something, it isn't building, will investigate. |
Thanks @nvborisenko |
Description
Provide examples to intercept network in .NET
Motivation and Context
Fixing lack of docs
Types of changes
Checklist