buildbot.config unit tests

Some work on unit tests of buildbot.config package. Improved test coverage and removed dead code.