Hi,
Firefox itself doesn't have a handy mechanism for running "headless",
but as Carlos and Mirko suggest it's pretty easy to do on Linux. I'd
suggest calling "quit" on your webdriver instances in the tear down of
your tests. This will quit any open instances of webdriver, and will
close any open windows.
If you're using the InternetExplorerDriver, then you can the following
to cause IE to run in headless mode:
((InternetExplorerDriver) driver).setVisible(false);
Regards,
Simon