Test framework for UI + SQL tests

@nockertsb please review