File tree Expand file tree Collapse file tree 2 files changed +8
-6
lines changed 
selenium/webdriver/remote 
test/selenium/webdriver/common Expand file tree Collapse file tree 2 files changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -1047,6 +1047,13 @@ def start_devtools(self):
10471047            import_cdp ()
10481048
10491049            if  not  devtools :
1050+                 if  self .caps ["browserName" ].lower () ==  "firefox" :
1051+                     warnings .warn (
1052+                         "CDP support for Firefox is deprecated and will be removed in future versions. Please switch to WebDriver BiDi." ,
1053+                         DeprecationWarning ,
1054+                         stacklevel = 2 ,
1055+                     )
1056+ 
10501057                if  self .caps .get ("se:cdp" ):
10511058                    ws_url  =  self .caps .get ("se:cdp" )
10521059                    version  =  self .caps .get ("se:cdpVersion" ).split ("." )[0 ]
@@ -1127,11 +1134,6 @@ def _get_cdp_details(self):
11271134        if  _firefox :
11281135            # Mozilla Automation Team asked to only support 85 
11291136            # until WebDriver Bidi is available. 
1130-             warnings .warn (
1131-                 "CDP support for Firefox is deprecated and will be removed in future versions. Please switch to WebDriver BiDi." ,
1132-                 DeprecationWarning ,
1133-                 stacklevel = 2 ,
1134-             )
11351137            version  =  85 
11361138        else :
11371139            version  =  re .search (r".*/(\d+)\." , browser_version ).group (1 )
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ def test_check_console_messages(driver, pages):
2525        devtools , connection  =  driver .start_devtools ()
2626    console_api_calls  =  []
2727
28-     if  driver .capabilities ["browserName" ] ==  "firefox" :
28+     if  driver .caps ["browserName" ]. lower ()  ==  "firefox" :
2929        assert  (
3030            record [0 ].message .args [0 ]
3131            ==  "CDP support for Firefox is deprecated and will be removed in future versions. Please switch to WebDriver BiDi." 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments