Package com.rallydev.rest.request

Examples of com.rallydev.rest.request.GetRequest


        response.add("Defect", defect);
        defect.add("Errors", new JsonArray());
        defect.add("Warnings", new JsonArray());
        defect.addProperty("_ref", "/defect/1234");

        GetRequest request = new GetRequest("/defect/1234");
        doReturn(new Gson().toJson(response)).when(api.client).doGet(request.toUrl());
        GetResponse getResponse = api.get(request);

        verify(api.client).doGet(request.toUrl());
        Assert.assertTrue(getResponse.wasSuccessful());
        JsonObject obj = getResponse.getObject();
        assertEquals(obj.get("_ref").getAsString(), "/defect/1234");
    }
View Full Code Here

TOP

Related Classes of com.rallydev.rest.request.GetRequest

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.