Since things like the URL of the website to test, login and password may be common to a whole suite of Selenium 2 programs, how can they be centralized ? I am using Python, so the answer maybe to use a super-class which has these common values.
Post script
I did try a 'super class' inherited from unittest.TestCase
which had the setUp
and tearDown
methods. The inherited sub-class had the core test code. This sub class also had import unittest
for cross-referencing code. But i found that the test time doubled with this approach. Maybe just my code, but i decided to globally edit properties in Eclipse.