当前位置: 首页>>代码示例>>Java>>正文


Java UsageItem类代码示例

本文整理汇总了Java中guru.nidi.ramltester.core.UsageItem的典型用法代码示例。如果您正苦于以下问题:Java UsageItem类的具体用法?Java UsageItem怎么用?Java UsageItem使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


UsageItem类属于guru.nidi.ramltester.core包,在下文中一共展示了UsageItem类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: testRequestAndResponse

import guru.nidi.ramltester.core.UsageItem; //导入依赖的package包/类
@Test
public void testRequestAndResponse() throws IOException {
    final SimpleReportAggregator aggregator = new SimpleReportAggregator();
    final RamlHttpClient client = baseClient.aggregating(aggregator);

    send(client, "http://localhost:8081/greetings?nofilter");
    send(client, "http://localhost:8081/greeting?nofilter");
    send(client, "http://localhost:8081/greeting?nofilter&name=ddd");
    send(client, "http://localhost:8081/greeting?nofilter&name=ddd&param=bla");

    assertUsage(aggregator.getUsage(), EnumSet.allOf(UsageItem.class));
}
 
开发者ID:nidi3,项目名称:raml-tester-uc-servlet,代码行数:13,代码来源:HttpComponentsTest.java

示例2: verify

import guru.nidi.ramltester.core.UsageItem; //导入依赖的package包/类
@Override
protected void verify() throws Throwable {
    final Usage usage = usageProvider.getUsage();
    for (final UsageItem item : items) {
        assertThat(item.get(usage), new EmptyMatcher(new Message("usage." + item.name()).toString()));
    }
}
 
开发者ID:nidi3,项目名称:raml-tester,代码行数:8,代码来源:ExpectedUsage.java

示例3: assertUsage

import guru.nidi.ramltester.core.UsageItem; //导入依赖的package包/类
private void assertUsage(Usage usage, EnumSet<UsageItem> usageItems) {
    for (UsageItem usageItem : usageItems) {
        assertEquals(usageItem.name(), 0, usageItem.get(usage).size());
    }
}
 
开发者ID:nidi3,项目名称:raml-tester-uc-servlet,代码行数:6,代码来源:HttpComponentsTest.java

示例4: ExpectedUsage

import guru.nidi.ramltester.core.UsageItem; //导入依赖的package包/类
public ExpectedUsage(UsageProvider usageProvider, UsageItem... items) {
    this.usageProvider = usageProvider;
    this.items = items.length == 0 ? EnumSet.allOf(UsageItem.class) : EnumSet.copyOf(Arrays.asList(items));
}
 
开发者ID:nidi3,项目名称:raml-tester,代码行数:5,代码来源:ExpectedUsage.java


注:本文中的guru.nidi.ramltester.core.UsageItem类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。