@@ -29,14 +29,8 @@ nature and relationship in the tree to return a value.
2929{{< tab header="Java" text=true >}}
3030{{< gh-codeblock path="examples/java/src/test/java/dev/selenium/elements/InformationTest.java#L20-L25" >}}
3131{{< /tab >}}
32- {{< tab header="Python" >}}
33-
34- # Navigate to the url
35- driver.get("https://www.selenium.dev/selenium/web/inputs.html ")
36-
37- # Get boolean value for is element display
38- is_email_visible = driver.find_element(By.NAME, "email_input").is_displayed()
39-
32+ {{< tab header="Python" text=true >}}
33+ {{< gh-codeblock path="examples/python/tests/elements/test_information.py#L12-L15" >}}
4034{{< /tab >}}
4135{{< tab header="CSharp" text=true >}}
4236{{< gh-codeblock path="examples/dotnet/SeleniumDocs/Elements/InformationTest.cs#L18-L23" >}}
@@ -69,12 +63,8 @@ is_email_visible = driver.find_element(By.NAME, "email_input").is_displayed()
6963{{< tab header="Java" text=true >}}
7064{{< gh-codeblock path="examples/java/src/test/java/dev/selenium/elements/InformationTest.java#L27-L30" >}}
7165{{< /tab >}}
72- {{< tab header="Python" >}}
73- # Navigate to url
74- driver.get("https://www.selenium.dev/selenium/web/inputs.html ")
75-
76- # Returns true if element is enabled else returns false
77- value = driver.find_element(By.NAME, 'button_input').is_enabled()
66+ {{< tab header="Python" text=true >}}
67+ {{< gh-codeblock path="examples/python/tests/elements/test_information.py#L19" >}}
7868{{< /tab >}}
7969{{< tab header="CSharp" text=true >}}
8070{{< gh-codeblock path="examples/dotnet/SeleniumDocs/Elements/InformationTest.cs#L25-L28" >}}
@@ -105,12 +95,8 @@ value = driver.find_element(By.NAME, 'button_input').is_enabled()
10595{{< tab header="Java" text=true >}}
10696{{< gh-codeblock path="examples/java/src/test/java/dev/selenium/elements/InformationTest.java#L32-L35" >}}
10797{{< /tab >}}
108- {{< tab header="Python" >}}
109- # Navigate to url
110- driver.get("https://www.selenium.dev/selenium/web/inputs.html ")
111-
112- # Returns true if element is checked else returns false
113- value = driver.find_element(By.NAME, "checkbox_input").is_selected()
98+ {{< tab header="Python" text=true >}}
99+ {{< gh-codeblock path="examples/python/tests/elements/test_information.py#L23" >}}
114100{{< /tab >}}
115101{{< tab header="CSharp" text=true >}}
116102{{< gh-codeblock path="examples/dotnet/SeleniumDocs/Elements/InformationTest.cs#L30-L33" >}}
@@ -139,12 +125,8 @@ val attr = driver.findElement(By.name("checkbox_input")).isSelected()
139125{{< tab header="Java" text=true >}}
140126{{< gh-codeblock path="examples/java/src/test/java/dev/selenium/elements/InformationTest.java#L37-L40" >}}
141127{{< /tab >}}
142- {{< tab header="Python" >}}
143- # Navigate to url
144- driver.get("https://www.selenium.dev/selenium/web/inputs.html ")
145-
146- # Returns TagName of the element
147- attr = driver.find_element(By.NAME, "email_input").tag_name
128+ {{< tab header="Python" text=true >}}
129+ {{< gh-codeblock path="examples/python/tests/elements/test_information.py#L27" >}}
148130{{< /tab >}}
149131{{< tab header="CSharp" text=true >}}
150132{{< gh-codeblock path="examples/dotnet/SeleniumDocs/Elements/InformationTest.cs#L35-L38" >}}
@@ -179,13 +161,9 @@ val attr = driver.findElement(By.name("email_input")).getTagName()
179161{{< tab header="Java" text=true >}}
180162{{< gh-codeblock path="examples/java/src/test/java/dev/selenium/elements/InformationTest.java#L42-L46" >}}
181163{{< /tab >}}
182- {{< tab header="Python" >}}
183- # Navigate to url
184- driver.get("https://www.selenium.dev/selenium/web/inputs.html ")
185-
186- # Returns height, width, x and y coordinates referenced element
187- res = driver.find_element(By.NAME, "range_input").rect
188- {{< /tab >}}
164+ {{< tab header="Python" text=true >}}
165+ {{< gh-codeblock path="examples/python/tests/elements/test_information.py#L31" >}}
166+ {{< /tab >}}
189167{{< tab header="CSharp" text=true >}}
190168{{< gh-codeblock path="examples/dotnet/SeleniumDocs/Elements/InformationTest.cs#L40-L47" >}}
191169{{< /tab >}}
@@ -215,14 +193,9 @@ println(res.getX())
215193{{< tab header="Java" text=true >}}
216194{{< gh-codeblock path="examples/java/src/test/java/dev/selenium/elements/InformationTest.java#L49-L51" >}}
217195{{< /tab >}}
218- {{< tab header="Python" >}}
219- # Navigate to Url
220- driver.get('https://www.selenium.dev/selenium/web/colorPage.html ')
221-
222- # Retrieves the computed style property 'color' of linktext
223- cssValue = driver.find_element(By.ID, "namedColor").value_of_css_property('background-color')
224-
225- {{< /tab >}}
196+ {{< tab header="Python" text=true >}}
197+ {{< gh-codeblock path="examples/python/tests/elements/test_information.py#L35-L37" >}}
198+ {{< /tab >}}
226199{{< tab header="CSharp" text=true >}}
227200{{< gh-codeblock path="examples/dotnet/SeleniumDocs/Elements/InformationTest.cs#L49-L51" >}}
228201{{< /tab >}}
@@ -249,12 +222,8 @@ val cssValue = driver.findElement(By.id("namedColor")).getCssValue("background-c
249222{{< tab header="Java" text=true >}}
250223{{< gh-codeblock path="examples/java/src/test/java/dev/selenium/elements/InformationTest.java#L54-L57" >}}
251224{{< /tab >}}
252- {{< tab header="Python" >}}
253- # Navigate to url
254- driver.get("https://www.selenium.dev/selenium/web/linked_image.html ")
255-
256- # Retrieves the text of the element
257- text = driver.find_element(By.ID, "justanotherlink").text
225+ {{< tab header="Python" text=true >}}
226+ {{< gh-codeblock path="examples/python/tests/elements/test_information.py#L41" >}}
258227{{< /tab >}}
259228{{< tab header="CSharp" text=true >}}
260229{{< gh-codeblock path="examples/dotnet/SeleniumDocs/Elements/InformationTest.cs#L53-L56" >}}
@@ -284,18 +253,9 @@ with the DOM attribute or property of the element.
284253{{< tab header="Java" text=true >}}
285254{{< gh-codeblock path="examples/java/src/test/java/dev/selenium/elements/InformationTest.java#L60-L65" >}}
286255{{< /tab >}}
287- {{< tab header="Python" >}}
288-
289- # Navigate to the url
290- driver.get("https://www.selenium.dev/selenium/web/inputs.html ")
291-
292- # Identify the email text box
293- email_txt = driver.find_element(By.NAME, "email_input")
294-
295- # Fetch the value property associated with the textbox
296- value_info = email_txt.get_attribute("value")
297-
298- {{< /tab >}}
256+ {{< tab header="Python" text=true >}}
257+ {{< gh-codeblock path="examples/python/tests/elements/test_information.py#L44-L46" >}}
258+ {{< /tab >}}
299259{{< tab header="CSharp" text=true >}}
300260{{< gh-codeblock path="examples/dotnet/SeleniumDocs/Elements/InformationTest.cs#L58-L63" >}}
301261{{< /tab >}}
0 commit comments