From d4146d6dbeb280dd3534671f53ad6b601040d328 Mon Sep 17 00:00:00 2001 From: Gintautas Miselis Date: Sun, 20 Dec 2020 11:36:00 +0200 Subject: [PATCH] Gherkin Loader: strip trailing backslash from namespace Fixes #6032 --- src/Codeception/Test/Loader/Gherkin.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Codeception/Test/Loader/Gherkin.php b/src/Codeception/Test/Loader/Gherkin.php index bad45189d6..1e5f0f9053 100644 --- a/src/Codeception/Test/Loader/Gherkin.php +++ b/src/Codeception/Test/Loader/Gherkin.php @@ -68,7 +68,7 @@ protected function fetchGherkinSteps() if (empty($this->steps) && empty($contexts['default']) && $this->settings['actor']) { // if no context is set, actor to be a context $actorContext = $this->settings['namespace'] - ? rtrim($this->settings['namespace'] . '\\' . $this->settings['actor'], '\\') + ? rtrim($this->settings['namespace'], '\\') . '\\' . rtrim($this->settings['actor'], '\\') : $this->settings['actor']; if ($actorContext) { $contexts['default'][] = $actorContext;