Package com.jcabi.github

Examples of com.jcabi.github.Reference


     * MkReference can fetch json.
     * @throws Exception - If something goes wrong.
     */
    @Test
    public void fetchesJson() throws Exception {
        final Reference ref = this.reference();
        final JsonObject json = ref.json();
        MatcherAssert.assertThat(
            json.getString("ref"),
            Matchers.is("refs/tags/hello")
        );
        MatcherAssert.assertThat(
View Full Code Here


     * MkReference should be able to patch itself.
     * @throws Exception - If something goes wrong.
     */
    @Test
    public void patchesRef() throws Exception {
        final Reference ref = this.reference();
        final JsonObject json = Json.createObjectBuilder()
            .add("sha", "testshaPATCH")
            .build();
        ref.patch(json);
        MatcherAssert.assertThat(
            ref.json().getString("sha"),
            Matchers.is("testshaPATCH")
        );
    }
View Full Code Here

TOP

Related Classes of com.jcabi.github.Reference

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.