I wonder if there is any way I can add new glues during the steps. I have one step that should add new packages depending on the result so I cannot give my options as CucumberOptions.
import org.junit.runner.RunWith;
import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
@CucumberOptions(
features = {"src/featureFiles/Employee_WeeklySchedule.feature"},
glue = { "magictester.core.glues" }
plugin = {"html:target/results" },
tags = {"@Runme"}
)
How can that be done? How can add/remove glues to cucumberOptions after test started?