A versatile test rig for the evaluation of thermionic electron guns