• 如果您觉得本站非常有看点,那么赶紧使用Ctrl+D 收藏吧

Java AbstractMapAssert类的典型用法和代码示例

java 6次浏览

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

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

示例1: asMap

点赞 2

import org.assertj.core.api.AbstractMapAssert; //导入依赖的package包/类
/**
 * Verifies that the actual value is a map, and returns a map assertion, to allow
 * chaining of map-specific assertions from this call.
 * @return a map assertion object
 */
@SuppressWarnings("unchecked")
public AbstractMapAssert<?, ?, Object, Object> asMap() {
	Objects.instance().assertIsInstanceOf(this.info, this.actual, Map.class);
	return Assertions.assertThat((Map<Object, Object>) this.actual);
}
 

开发者ID:vikrammane23,
项目名称:https-github.com-g0t4-jenkins2-course-spring-boot,
代码行数:11,
代码来源:ObjectContentAssert.java

示例2: then

点赞 2

import org.assertj.core.api.AbstractMapAssert; //导入依赖的package包/类
/**
 * Delegate call to {@link org.assertj.core.api.Assertions#assertThat(Map)}
 */
default <K, V> AbstractMapAssert<?, ? extends Map<K, V>, K, V> then(Map<K, V> actual) {
	fluentBdd().verification.recordThen(this);
	return DELEGATE.assertThat(actual);
}
 

开发者ID:theangrydev,
项目名称:fluent-bdd,
代码行数:8,
代码来源:WithFluentAssertJ.java

示例3: and

点赞 2

import org.assertj.core.api.AbstractMapAssert; //导入依赖的package包/类
/**
 * Delegate call to {@link org.assertj.core.api.Assertions#assertThat(Map)}
 */
default <K, V> AbstractMapAssert<?, ? extends Map<K, V>, K, V> and(Map<K, V> actual) {
	fluentBdd().verification.recordThen(this);
	return DELEGATE.assertThat(actual);
}
 

开发者ID:theangrydev,
项目名称:fluent-bdd,
代码行数:8,
代码来源:WithFluentAssertJ.java

示例4: extractingJsonPathMapValue

点赞 1

import org.assertj.core.api.AbstractMapAssert; //导入依赖的package包/类
/**
 * Extract the map value at the given JSON path for further object assertions.
 * @param expression the {@link JsonPath} expression
 * @param args arguments to parameterize the {@code JsonPath} expression with, using
 * formatting specifiers defined in {@link String#format(String, Object...)}
 * @return a new assertion object whose object under test is the extracted item
 * @throws AssertionError if the path is not valid or does not result in a map
 */
@SuppressWarnings("unchecked")
public AbstractMapAssert<?, ?, Object, Object> extractingJsonPathMapValue(
		CharSequence expression, Object... args) {
	return Assertions.assertThat(
			extractingJsonPathValue(expression, args, Map.class, "a map"));
}
 

开发者ID:vikrammane23,
项目名称:https-github.com-g0t4-jenkins2-course-spring-boot,
代码行数:15,
代码来源:JsonContentAssert.java

示例5: expect

点赞 1

import org.assertj.core.api.AbstractMapAssert; //导入依赖的package包/类
/**
 * A little wrapper over {@code assertThat} that just mention that this what we expect from the test. So if the
 * expectation fails, it's probably the test that is wrong, not the implementation.
 *
 * @param actual actual value
 * @return an AssertJ assertion
 */
protected static <K, V> AbstractMapAssert<?, ? extends Map<K, V>, K, V> expect(Map<K, V> actual) {
  return assertThat(actual);
}
 

开发者ID:ehcache,
项目名称:ehcache3,
代码行数:11,
代码来源:AbstractCalculationTest.java


版权声明:本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系管理员进行删除。
喜欢 (0)