I guess what you really mean by saying
scenario in your question is actually called a
suite .. that would be something on the same level as "Acceptance" or "Functional" suites.
We have one specific case, where we need to start a http tunel (simply an external app) before a whole bunch of test (a suite) can be ran. How this can be solved is by creating a module with
_afterSuite() methods. Then you register this module in your
.yml file for the suite.
class MagicPreparationHelper extends \Codeception\Module
public function _beforeSuite($settings = )
// have a look what is inside $settings, if you need that
echo "Magic starts here \n";
public function _afterSuite()
echo "Magic ends here \n";
# Codeception Test Suite Configuration
# Suite for magic tests.
you can read more here: