Modularize functional testing