File tree Expand file tree Collapse file tree 2 files changed +25
-1
lines changed Expand file tree Collapse file tree 2 files changed +25
-1
lines changed Original file line number Diff line number Diff line change 78
78
sb .js_checking_on = False
79
79
sb .recorder_mode = False
80
80
sb .recorder_ext = False
81
+ sb .record_sleep = False
82
+ sb .rec_behave = False
81
83
sb .report_on = False
82
84
sb .is_pytest = False
83
85
sb .slow_mode = False
Original file line number Diff line number Diff line change 3
3
4
4
5
5
class DownloadTests (BaseCase ):
6
- def test_download_files (self ):
6
+ def test_download_chromedriver_notes (self ):
7
+ self .open ("https://chromedriver.chromium.org/downloads" )
8
+ notes_file = "notes.txt"
9
+ notes_link = (
10
+ "https://chromedriver.storage.googleapis.com"
11
+ "/101.0.4951.41/%s" % notes_file
12
+ )
13
+ self .download_file (notes_link )
14
+ self .assert_downloaded_file (notes_file )
15
+ notes_path = self .get_path_of_downloaded_file (notes_file )
16
+ with open (notes_path , "r" ) as f :
17
+ notes_data = f .read ()
18
+ self .assert_true (len (notes_data ) > 100 ) # Verify file not empty
19
+ text = "Switching to nested frame fails with chrome/chromedriver 100"
20
+ self .assert_true (text in notes_data ) # Verify file has expected data
21
+
22
+ def test_download_files_from_pypi_with_edge (self ):
23
+ if self .browser != "edge" :
24
+ self .open ("data:," )
25
+ print ("\n This test is only for Microsoft Edge (Chromium)!" )
26
+ print (' (Run this test using "--edge" or "--browser=edge")' )
27
+ self .skip ('Use "--edge" or "--browser=edge"' )
28
+
7
29
self .open ("https://pypi.org/project/seleniumbase/#files" )
8
30
pkg_header = self .get_text ("h1.package-header__name" ).strip ()
9
31
pkg_name = pkg_header .replace (" " , "-" )
You can’t perform that action at this time.
0 commit comments