Add an explicit setup stage for scenarios
Scenarios are assuming that they are ready to run (i.e. on the correct page). Basically, scenarios are dependents on the global application state. To make this clear, I think that a #setup step could help write new tests because you may assert/navigate/query the application state for all your assumptions and separate that from the actual interactions of the scenario.
# prepare the application state
def setup
Page::Group::Show.perform do |page|
create_group unless page.has_subgroup?(Runtime::Namespace.name)
end
end
# navigate to some other page
def setup
Page::Admin::Menu.act { ... }
end
# or simply prepare the sandbox
def setup
Scenario::Gitlab::Sandbox::Prepare.perform
end