-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3317 from seleniumbase/mostly-pytest-updates
Mostly `pytest` updates
- Loading branch information
Showing
18 changed files
with
254 additions
and
29 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
from seleniumbase import SB | ||
|
||
with SB(uc=True, test=True, locale_code="en", incognito=True) as sb: | ||
url = "https://www.radwell.com/en-US/Search/Advanced/" | ||
sb.activate_cdp_mode(url) | ||
sb.sleep(3) | ||
sb.cdp.press_keys("form#basicsearch input", "821C-PM-111DA-142") | ||
sb.sleep(1) | ||
sb.cdp.click('[value="Search Icon"]') | ||
sb.sleep(3) | ||
sb.cdp.assert_text("MAC VALVES INC", "a.manufacturer-link") | ||
sb.cdp.highlight("a.manufacturer-link") | ||
sb.sleep(1) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
from seleniumbase import SB | ||
|
||
with SB( | ||
uc=True, test=True, locale_code="en", incognito=True, ad_block=True | ||
) as sb: | ||
url = "https://www.tiktok.com/@startrek?lang=en" | ||
sb.activate_cdp_mode(url) | ||
sb.sleep(2.5) | ||
sb.cdp.click('button:contains("Refresh")') | ||
sb.sleep(1.5) | ||
print(sb.cdp.get_text('h2[data-e2e="user-bio"]')) | ||
for i in range(55): | ||
sb.cdp.scroll_down(12) | ||
sb.sleep(0.06) | ||
sb.sleep(1) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
from seleniumbase import SB | ||
|
||
with SB(uc=True, test=True, locale_code="en", ad_block=True) as sb: | ||
url = "https://www.united.com/en/us" | ||
sb.activate_cdp_mode(url) | ||
sb.sleep(2.5) | ||
origin_input = 'input[placeholder="Origin"]' | ||
origin = "Boston, MA" | ||
destination_input = 'input[placeholder="Destination"]' | ||
destination = "San Diego, CA" | ||
sb.cdp.gui_click_element(origin_input) | ||
sb.sleep(1.2) | ||
sb.cdp.type(origin_input, origin) | ||
sb.sleep(1.2) | ||
sb.cdp.click('strong:contains("%s")' % origin) | ||
sb.sleep(1.2) | ||
sb.cdp.gui_click_element(destination_input) | ||
sb.sleep(1.2) | ||
sb.cdp.type(destination_input, destination) | ||
sb.sleep(1.2) | ||
sb.cdp.click('strong:contains("%s")' % destination) | ||
sb.sleep(1.2) | ||
sb.cdp.click('button[aria-label="Find flights"]') | ||
sb.sleep(6) | ||
flights = sb.find_elements('div[class*="CardContainer__block"]') | ||
print("**** Flights from %s to %s ****" % (origin, destination)) | ||
if not flights: | ||
print("* No flights found!") | ||
for flight in flights: | ||
print("* " + flight.text.split(" Destination")[0]) | ||
sb.sleep(1.5) |
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
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
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
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
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
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
# seleniumbase package | ||
__version__ = "4.33.3" | ||
__version__ = "4.33.4" |
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
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
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
Oops, something went wrong.