Reformatted apptest.py, to make comparisons with branch 1.x easier.