Package com.jcabi.http.mock

Examples of com.jcabi.http.mock.MkContainer.stop()


            MatcherAssert.assertThat(
                query.method(),
                Matchers.equalTo(Request.DELETE)
            );
        } finally {
            container.stop();
        }
    }

    /**
     * Create and return repo for testing.
View Full Code Here


        );
        MatcherAssert.assertThat(
            new Pull.Smart(pull).title(),
            Matchers.equalTo(title)
        );
        container.stop();
    }

    /**
     * RtPulls can get a single pull request.
     * @throws Exception if some problem inside
View Full Code Here

        final Pull pull = pulls.get(Tv.BILLION);
        MatcherAssert.assertThat(
            new Pull.Smart(pull).title(),
            Matchers.equalTo(title)
        );
        container.stop();
    }

    /**
     * RtPulls can iterate pulls.
     * @throws Exception if there is any error
View Full Code Here

        );
        MatcherAssert.assertThat(
            pulls.iterate(),
            Matchers.<Pull>iterableWithSize(2)
        );
        container.stop();
    }

    /**
     * Create and return JsonObject to test.
     * @param title The title of the pull request
View Full Code Here

            MatcherAssert.assertThat(
                query.uri().toString(),
                Matchers.endsWith("/repos/john/test/releases/assets/2")
            );
        } finally {
            container.stop();
        }
    }

    /**
     * RtReleaseAsset can remove itself.
View Full Code Here

            MatcherAssert.assertThat(
                query.method(),
                Matchers.equalTo(Request.DELETE)
            );
        } finally {
            container.stop();
        }
    }

    /**
     * RtReleaseAsset can stream raw content.
View Full Code Here

            MatcherAssert.assertThat(
                IOUtils.toString(stream),
                Matchers.notNullValue()
            );
        } finally {
            container.stop();
        }
    }

    /**
     * This method returns a Release for testing.
View Full Code Here

        final RtJson json = new RtJson(new ApacheRequest(container.home()));
        MatcherAssert.assertThat(
            json.fetch().getString("body"),
            Matchers.equalTo("hi")
        );
        container.stop();
    }

    /**
     * RtJson can execute PATCH request.
     *
 
View Full Code Here

        );
        MatcherAssert.assertThat(
            container.take().method(),
            Matchers.equalTo("PATCH")
        );
        container.stop();
    }
}
View Full Code Here

            MatcherAssert.assertThat(
                query.method(),
                Matchers.equalTo(Request.DELETE)
            );
        } finally {
            container.stop();
        }
    }

    /**
     * RtComment can return its JSon description.
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.