title: Spring-boot application test - memory issues
body: <p>I have a spring-boot test that starts my application and run some tests on it.</p>
  
  <p>I am having a problem setting the application heap size.</p>
  
  <p>When I run it through maven and surefire with memory parameters set, it all works, but trying to run it from my IDE (Intellij) doesn't, and I get java.lang.OutOfMemoryError: Java heap space.</p>
  
  <pre><code>@RunWith(Parameterized.class)
  @SpringApplicationConfiguration(classes = MyApplication.class)
  @WebAppConfiguration
  public class MyTest {
  
      public MyTest(String name, URL url) {
          this.url = url;
      }
  
      @Parameterized.Parameters...
      public static Iterable&lt;Object[]&gt; tests() throws IOException {
         ....
      }
  
      @Before
      public void setUpContext() throws Exception {
          new TestContextManager(getClass()).prepareTestInstance(this);
      }
  
  
      @Test
      public void doSomething() throws Exception {
         ...
      }
  }
  </code></pre>