Fix random tests
Merge remote-tracking branch 'origin/master' into MasterBugFixing