suppose you have the following situation while testing a spring context
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(classes = {ConfigClass.class})
public class IntegrationTest {
@ClassRule
static PluginThatSetsUpSomethingEmbedded pluginRule = new PluginThatSetsUpSomethingEmbedded();
}
now one of my Spring beans needs something that can only come out of the rule, like:
pluginRule.getEmbeddedToolConfig()
how can I provide my bean with that config, notice that the rule is ClassRule and is static too...