Replicates issue #1389 from codeception/codeception