Search in sources :

Example 6 with FunctionalTestHelper

use of org.neo4j.doc.server.helpers.FunctionalTestHelper in project neo4j-documentation by neo4j.

the class NeoServerJAXRSDocIT method shouldMakeJAXRSClassesAvailableViaHTTP.

@Test
public void shouldMakeJAXRSClassesAvailableViaHTTP() throws Exception {
    CommunityWebContainerBuilder builder = CommunityWebContainerBuilder.builder();
    webContainer = WebContainerHelper.createContainer(builder, folder, true);
    FunctionalTestHelper functionalTestHelper = new FunctionalTestHelper(webContainer);
    JaxRsResponse response = new RestRequest().get(functionalTestHelper.baseUri().toASCIIString());
    assertEquals(200, response.getStatus());
}
Also used : CommunityWebContainerBuilder(org.neo4j.doc.server.helpers.CommunityWebContainerBuilder) RestRequest(org.neo4j.doc.server.rest.RestRequest) FunctionalTestHelper(org.neo4j.doc.server.helpers.FunctionalTestHelper) JaxRsResponse(org.neo4j.doc.server.rest.JaxRsResponse) Test(org.junit.Test)

Example 7 with FunctionalTestHelper

use of org.neo4j.doc.server.helpers.FunctionalTestHelper in project neo4j-documentation by neo4j.

the class AutoIndexWithNonDefaultConfigurationThroughRESTAPIDocIT method allocateServer.

@BeforeClass
public static void allocateServer() throws IOException {
    server = CommunityServerBuilder.server().usingDataDir(staticFolder.getRoot().getAbsolutePath()).withAutoIndexingEnabledForNodes("foo", "bar").build();
    server.start();
    functionalTestHelper = new FunctionalTestHelper(server);
}
Also used : FunctionalTestHelper(org.neo4j.doc.server.helpers.FunctionalTestHelper) BeforeClass(org.junit.BeforeClass)

Example 8 with FunctionalTestHelper

use of org.neo4j.doc.server.helpers.FunctionalTestHelper in project neo4j-documentation by neo4j.

the class CompactJsonDocIT method setupServer.

@BeforeClass
public static void setupServer() throws IOException {
    functionalTestHelper = new FunctionalTestHelper(server());
    helper = functionalTestHelper.getGraphDbHelper();
}
Also used : FunctionalTestHelper(org.neo4j.doc.server.helpers.FunctionalTestHelper) BeforeClass(org.junit.BeforeClass)

Example 9 with FunctionalTestHelper

use of org.neo4j.doc.server.helpers.FunctionalTestHelper in project neo4j-documentation by neo4j.

the class DatabaseMetadataServiceDocIT method setupServer.

@BeforeClass
public static void setupServer() throws IOException {
    functionalTestHelper = new FunctionalTestHelper(server());
    helper = functionalTestHelper.getGraphDbHelper();
}
Also used : FunctionalTestHelper(org.neo4j.doc.server.helpers.FunctionalTestHelper) BeforeClass(org.junit.BeforeClass)

Example 10 with FunctionalTestHelper

use of org.neo4j.doc.server.helpers.FunctionalTestHelper in project neo4j-documentation by neo4j.

the class GetRelationshipPropertiesDocIT method setupServer.

@BeforeClass
public static void setupServer() throws IOException {
    functionalTestHelper = new FunctionalTestHelper(server());
    helper = functionalTestHelper.getGraphDbHelper();
    setupTheDatabase();
}
Also used : FunctionalTestHelper(org.neo4j.doc.server.helpers.FunctionalTestHelper) BeforeClass(org.junit.BeforeClass)

Aggregations

FunctionalTestHelper (org.neo4j.doc.server.helpers.FunctionalTestHelper)23 BeforeClass (org.junit.BeforeClass)12 Test (org.junit.Test)11 JaxRsResponse (org.neo4j.doc.server.rest.JaxRsResponse)9 Matchers.containsString (org.hamcrest.Matchers.containsString)4 RestRequest (org.neo4j.doc.server.rest.RestRequest)3 Documented (org.neo4j.kernel.impl.annotations.Documented)3 Title (org.neo4j.test.TestData.Title)3 File (java.io.File)2 FileUtils.readTextFile (org.neo4j.io.fs.FileUtils.readTextFile)2 NeoServer (org.neo4j.server.NeoServer)2 CommunityWebContainerBuilder (org.neo4j.doc.server.helpers.CommunityWebContainerBuilder)1