mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
XDebuggerAssertions: Add missing assertVariableTypeMatches overloads
GitOrigin-RevId: 4c81b8d2f1c3ff73cd8a6a06c89d06a54f361ded
This commit is contained in:
committed by
intellij-monorepo-bot
parent
e12eece974
commit
5f5cf4e666
+20
-4
@@ -248,17 +248,33 @@ public class XDebuggerAssertions extends XDebuggerTestUtil {
|
||||
public static void assertVariableTypeMatches(@NotNull XValue var,
|
||||
@Nullable String name,
|
||||
@Nullable @Language("RegExp") String typePattern) {
|
||||
assertVariableTypeMatches(var, name, typePattern, XDebuggerTestUtil::waitFor);
|
||||
assertVariableTypeMatches(var, name, typePattern, null);
|
||||
}
|
||||
|
||||
public static void assertVariableTypeMatches(@NotNull XValue var,
|
||||
@Nullable String name,
|
||||
@Nullable @Language("RegExp") String typePattern,
|
||||
@Nullable String value) {
|
||||
assertVariableTypeMatches(var, name, typePattern, value, null);
|
||||
}
|
||||
|
||||
public static void assertVariableTypeMatches(@NotNull XValue var,
|
||||
@Nullable String name,
|
||||
@Nullable @Language("RegExp") String typePattern,
|
||||
@Nullable String value,
|
||||
@Nullable Boolean hasChildren) {
|
||||
assertVariableTypeMatches(var, name, typePattern, value, hasChildren, null, XDebuggerTestUtil::waitFor);
|
||||
}
|
||||
|
||||
public static void assertVariableTypeMatches(@NotNull XValue var,
|
||||
@Nullable String name,
|
||||
@Nullable @Language("RegExp") String typePattern,
|
||||
@Nullable String value,
|
||||
@Nullable Boolean hasChildren,
|
||||
@Nullable Icon icon,
|
||||
@NotNull BiFunction<Semaphore, Long, Boolean> waitFunction) {
|
||||
XTestValueNode node = computePresentation(var, waitFunction);
|
||||
if (name != null) {
|
||||
assertEquals(name, node.myName);
|
||||
}
|
||||
assertVariable(node, name, null, value, hasChildren, icon);
|
||||
if (typePattern != null) {
|
||||
assertTrue("Expected type: " + typePattern + " Actual type: " + node.myType,
|
||||
node.myType != null && node.myType.matches(typePattern));
|
||||
|
||||
Reference in New Issue
Block a user