I want to load the Firefox Addon RequestPolicy. This is how i tried it:
rp = open(wd + "/requestpolicy.xpi")
firefoxProfile = FirefoxProfile()
firefoxProfile.add_extension(rp)
self.driver = webdriver.Firefox(firefoxProfile)
self.usr = user.User(self.driver, username, password, world)
self.usr.login()
No error, according to the Docs it should work, but it doesn't, it still starts without the addon.
Next thing i've tried is calling it this way:
self.driver = webdriver.Firefox(browser_profile=firefoxProfile)
Output:
TypeError: __init__() got an unexpected keyword argument 'browser_profile'
But this is an aspect of python i dont know much about. I got that idea because the source looks that way.