0

I am planning to use Webdriver to automate testing of my extension for Chrome. Till now I have been able to start chrome browser using selenium webdriver with extension loaded. Now I am stuck as to how to select different options inside extension using webdriver. I read this post which makes sense but I am not sure how to exactly implement it in webdriver. Also since my extension is on my local machine (and not on app store), the very command mentioned on the page (chrome-extension://mbopgmdnpcbohhpnfglgohlbhfongabi/popup.html) does not work for me.

I would appreciate any thoughts and/or I could be directed to any reading material.

curiousJ
  • 203
  • 1
  • 4
  • 11
  • Did any of the below suggestions get you going, @curiousJ? If not, let me know and I can scout about a bit more. I've spent some time working with Selenium, and I've had my share of frustrations with the Chrome driver in particular! – duhaime Aug 17 '14 at 13:01
  • @duhaime - I still haven't been able to select options inside extension, will dig more into it today – curiousJ Aug 18 '14 at 16:52

1 Answers1

1

Have you tried:

from selenium import webdriver
from selenium.webdriver.chrome.options import Options
chrome_options = Options()
chrome_options.add_argument("--disable-extensions")
driver = webdriver.Chrome(chrome_options=chrome_options)

(via this post). This blog post lists some of the things you can pass to chrome_options.add_argument(), and this post offers another potential solution. Hope this helps!

Community
  • 1
  • 1
duhaime
  • 25,611
  • 17
  • 169
  • 224
  • The first suggestion that you gave above was similar to what I used to load extension in Chrome when firing chrome using webdriver [link](http://stackoverflow.com/questions/25255102/unable-to-load-unpacked-extension-into-chrome-using-selenium-webdriver/25255402#25255402) – curiousJ Aug 18 '14 at 16:50