Test fixes

This commit is contained in:
dragonmacher
2026-05-18 14:16:04 -04:00
parent 060722d891
commit f847e4e66e
@@ -741,13 +741,6 @@ public class AnnotationTest extends AbstractGhidraHeadedIntegrationTest {
// Navigation performed by ProgramManager not tested due to use of spyServiceProvider
}
@Test
public void testVariableAnnotation_Basic() {
String rawComment = "{@variable Stack[0xa] MyFunction}";
String display = CommentUtils.getDisplayString(rawComment, program);
assertEquals("myVariable", display);
}
@Test
public void testVariableAnnotation_BasicModify() {
String rawComment = "{@variable myVariable MyFunction}";
@@ -765,21 +758,14 @@ public class AnnotationTest extends AbstractGhidraHeadedIntegrationTest {
}
@Test
public void testLocalAnnotation_UserMarked() {
String rawComment = "{@variable Stack[0xa] MyFunction}";
String display = CommentUtils.getDisplayString(rawComment, program);
assertEquals("myVariable", display);
}
@Test
public void testLocalAnnotation_UserMarkedModify() {
public void testLocalAnnotation_VariableAddress() {
String rawComment = "{@variable Stack[0xa] MyFunction}";
String display = CommentUtils.fixupAnnotations(rawComment, program, Address.NO_ADDRESS);
assertEquals("{@variable Stack[0xa] 01002000}", display);
}
@Test
public void testLocalAnnotation_UserMarkedModify_NoFunction() {
public void testLocalAnnotation_VariableAddress_NoFunction() {
String rawComment = "{@variable Stack[0xa]}";
String functionAddress = "01002000";
Address entryPoint = addr(functionAddress);