fix count when testing composite error output
don't color engine tracebacks in tests
py3: assign e so it survives outside the scope
Merge pull request #2964 from minrk/testcount

fix count when testing composite error output

and a py3 fix in the same test