Questions tagged [context-configuration]

20 questions
0
votes
2 answers

How to tell SpringBootTest to load all required classes without explicitly having to specify them

As far as I understand, you have two options with SpringBootTests: Load the whole application Load only what you need by specifying the classes explicitly However, if you do 2., depending on how large the part of the application is you want to…
Marian Klühspies
  • 15,824
  • 16
  • 93
  • 136
0
votes
0 answers

Spring context doesn't load my class in unittest

I can't get my unit test to load my configuration class. My test class is annotated: @RunWith(SpringJUnit4ClassRunner.class) @ActiveProfiles(profiles = "test") @ContextConfiguration (classes = ClientConfiguration.class) public class…
ed4becky
  • 1,488
  • 1
  • 17
  • 54
0
votes
1 answer

What is use of contextconfiglocation in web.xml of Spring-based web-app?

In Spring, what is purpose of ContextConfigLocation and also InternalResourceViewResolver? I did't get the purpose of these classes.
liviraj
  • 37
  • 2
  • 11
0
votes
0 answers

ContextConfigLocation java config

I am still new to java and spring and I still have some troubles with some context related topics. I am trying to have my context config files loaded from property file. I wanted to upgrade my spring 3 application to spring 4. Below configuration…
Leon230
  • 1
  • 2
0
votes
1 answer

get all Beans of type in SpringJUnit4ClassRunner

I have problems to find a suitable answer for my following test class: @ContextConfiguration("classpath:services.xml") @RunWith(SpringJUnit4ClassRunner.class) public class RunnableServiceTest { @Test public void testConfiguration(){ …
nano_nano
  • 12,351
  • 8
  • 55
  • 83
1
2