title: Why shouldn't you use a global variables for the Selenium webdriver?
body: <p>As I am new to OO programming this may seem a trite question.</p>
  
  <p>I am trying to write a basic End-User testing framework which has a class Pageobject with the majority of method code.</p>
  
  <p>I have a testing script which instantiates the selenium driver at the top-level and then I have a number of Page object method calls to "do stuff".</p>
  
  <p>If I instantiate the driver at the top-level then I need to pass the driver object to any method that needs it which is fine but I would like to minimise the number of parameters passed to a method call for the saake of readability.</p>
  
  <p>eg. home_page.login(this_user) reads a little better than home_page.login(this_user, selenium_driver).</p>
  
  <p>I know global variables are frowned upon so is there any other way that all method can have access to an object in a different scope.</p>