import com.jayway.restassured.module.mockmvc.RestAssuredMockMvc;
import org.junit.Before;
import org.junit.FixMethodOrder;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.MethodSorters;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
import org.springframework.test.context.web.WebAppConfiguration;
import org.springframework.web.context.WebApplicationContext;

import static com.jayway.restassured.module.mockmvc.RestAssuredMockMvc.given;
import static org.hamcrest.core.IsEqual.equalTo;


/**
 * Created by tmaugin on 08/04/2015.
 */
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations={"classpath:META-INF/spring/applicationContextTest.xml","classpath:META-INF/spring/dispatcherServletTest.xml"})
@WebAppConfiguration
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
public class ApplicationTest {

    @Autowired
    WebApplicationContext webApplicationContext;

    @Before public void
    setUp() {
        RestAssuredMockMvc.webAppContextSetup(webApplicationContext);
    }

    @Test
    public void test1_getApplicetion() {
        given()
                .contentType("application/json")
                .when()
                .get("/api/application")
                .then()
                .statusCode(200)
                .body("size()", equalTo(5));
    }
}
@@ -1,12 +1,177 @@
+import com.google.appengine.tools.development.testing.LocalDatastoreServiceTestConfig;%0Aimport com.google.appengine.tools.development.testing.LocalServiceTestHelper;%0A
 import com.j
@@ -240,22 +240,81 @@
 g.junit.
-Before
+AfterClass;%0Aimport org.junit.Before;%0Aimport org.junit.BeforeClass
 ;%0Aimport
@@ -1218,16 +1218,328 @@
 Test %7B%0A%0A
+    private static final LocalServiceTestHelper helper =%0A            new LocalServiceTestHelper(new LocalDatastoreServiceTestConfig());%0A%0A    @BeforeClass%0A    public static void beforeClass() %7B%0A        helper.setUp();%0A    %7D%0A%0A    @AfterClass%0A    public static void afterClass() %7B%0A        helper.tearDown();%0A    %7D%0A%0A
     @Aut

Use a GAE local datastore in unit tests