Package org.neo4j.smack.test.util

Examples of org.neo4j.smack.test.util.JaxRsResponse


        assertNotNull( map.get( "extensions_info" ) );
        assertNotNull( map.get( "batch" ) );
        assertEquals( Version.getKernelRevision(), map.get( "neo4j_version" ) );

        // Make sure advertised urls work
            JaxRsResponse response = RestRequest.req().get( getDataUri() );
        if ( map.get( "reference_node" ) != null )
        {
            response = RestRequest.req().get(
                    (String) map.get( "reference_node" ) );
            assertEquals( 200, response.getStatus() );
            response.close();
        }
        response = RestRequest.req().get( (String) map.get( "node_index" ) );
        assertTrue( response.getStatus() == 200 || response.getStatus() == 204 );
        response.close();

        response = RestRequest.req().get(
                (String) map.get( "relationship_index" ) );
        assertTrue( response.getStatus() == 200 || response.getStatus() == 204 );
        response.close();

        response = RestRequest.req().get( (String) map.get( "extensions_info" ) );
        assertEquals( 200, response.getStatus() );
        response.close();

        response = RestRequest.req().post( (String) map.get( "batch" ), "[]" );
        assertEquals( 200, response.getStatus() );
        response.close();
    }
View Full Code Here


public class ErrorHandlingIT extends AbstractRestFunctionalTestBase {

    @Test
    public void shouldReturn404OnMissingResource() throws Exception {
        JaxRsResponse response = RestRequest.req().post(getDataUri() + "some/bs/resource123/lol", "[]");
        assertEquals(404, response.getStatus());
        response.close();
    }
View Full Code Here

TOP

Related Classes of org.neo4j.smack.test.util.JaxRsResponse

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.