|
42 | 42 | DEFAULT_CHROMEDRIVER_VERSION = "2.44"
|
43 | 43 | DEFAULT_GECKODRIVER_VERSION = "v0.26.0"
|
44 | 44 | DEFAULT_EDGEDRIVER_VERSION = "79.0.309.65"
|
45 |
| -DEFAULT_OPERADRIVER_VERSION = "v.75.0.3770.100" |
| 45 | +DEFAULT_OPERADRIVER_VERSION = "v.81.0.4044.113" |
46 | 46 |
|
47 | 47 |
|
48 | 48 | def invalid_run_command():
|
@@ -336,13 +336,18 @@ def main(override=None):
|
336 | 336 | print("")
|
337 | 337 | elif name == "edgedriver" or name == "msedgedriver":
|
338 | 338 | if "darwin" in sys_plat or "linux" in sys_plat:
|
| 339 | + # Was expecting to be on a Windows OS at this point |
339 | 340 | raise Exception("Unexpected file format for msedgedriver!")
|
340 | 341 | expected_contents = (['Driver_Notes/',
|
341 | 342 | 'Driver_Notes/credits.html',
|
342 | 343 | 'Driver_Notes/LICENSE',
|
343 | 344 | 'msedgedriver.exe'])
|
344 |
| - if len(contents) != 4: |
| 345 | + if len(contents) > 4: |
345 | 346 | raise Exception("Unexpected content in EdgeDriver Zip file!")
|
| 347 | + for content in contents: |
| 348 | + if content not in expected_contents: |
| 349 | + raise Exception("Expected file [%s] missing from [%s]" % ( |
| 350 | + content, expected_contents)) |
346 | 351 | # Zip file is valid. Proceed.
|
347 | 352 | driver_path = None
|
348 | 353 | driver_file = None
|
@@ -376,12 +381,9 @@ def main(override=None):
|
376 | 381 | print("Making [%s %s] executable ..." % (driver_file, use_version))
|
377 | 382 | make_executable(driver_path)
|
378 | 383 | print("[%s] is now ready for use!" % driver_file)
|
379 |
| - print("Add folder path of Edge to System Environmental Variables!") |
380 | 384 | print("")
|
381 | 385 | elif name == "operadriver":
|
382 |
| - if len(contents) != 3: |
383 |
| - raise Exception("Unexpected content in OperaDriver Zip file!") |
384 |
| - elif sorted(contents) != sorted(expected_contents): |
| 386 | + if len(contents) > 3: |
385 | 387 | raise Exception("Unexpected content in OperaDriver Zip file!")
|
386 | 388 | # Zip file is valid. Proceed.
|
387 | 389 | driver_path = None
|
|
0 commit comments