PyIRCBot uses py.test. Several fixtures are provided to mock various parts of the PyIRCBot ecosystem. See them all in lib.py.
lib.py