Functional tests for ticket stages

I add further functional tests for the transition of ticket stages up to
and including stage "closed".