Prepare test framework for python3 compatibility

Some general changes to test framework and shared test code

See merge request !1936
6 jobs for master in 0 seconds
Status Job ID Name Coverage
  External
passed ERP5.CodingStyleTest-Master

02:33:59

failed ERP5.PerformanceTest-Master

00:35:17

failed ERP5.UnitTest-Master

03:52:48

passed SlapOS.Eggs.UnitTest-Master.Python2

00:25:44

passed SlapOS.Eggs.UnitTest-Master.Python3

00:31:37

passed Wendelin.UnitTest-Master

01:11:20