Skip to content
This repository has been archived by the owner on Dec 5, 2024. It is now read-only.

Commit

Permalink
Removed workaround
Browse files Browse the repository at this point in the history
Signed-off-by: Oleksii Korniienko <[email protected]>
  • Loading branch information
olkornii committed Jun 7, 2023
1 parent 4cffe6a commit 686ddb1
Showing 1 changed file with 8 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,24 +51,19 @@ public void testContextMenu() {
project.getProjectItem(EXAMPLE_TEST_CLASS_PATH).select();

try {
try {
new ContextMenuItem(new DefaultTree(),
new WithTextMatcher(new RegexMatcher(".*Run As.*")),
new WithTextMatcher(new RegexMatcher(".*RedDeer Test.*"))); // if it's the first run
} catch (CoreLayerException e) { // Launch configuration create with the same NAME as FILE NAME after first run
new ContextMenuItem(new DefaultTree(),
new WithTextMatcher(new RegexMatcher(".*Run As.*")),
new WithTextMatcher(new RegexMatcher(".*"+ EXAMPLE_TEST_CLASS_NAME + ".*"))); // if the launch configuration exists
}
new ContextMenuItem(new DefaultTree(),
new WithTextMatcher(new RegexMatcher(".*Run As.*")),
new WithTextMatcher(new RegexMatcher(".*RedDeer Test.*")));
} catch (CoreLayerException exc) {
fail("ContextMenuItem Run As -> RedDeer Test (" + EXAMPLE_TEST_CLASS_NAME + ") is missing");
fail("ContextMenuItem Run As -> RedDeer Test is missing");
}

try {
new ContextMenuItem(new DefaultTree(),
new WithTextMatcher(new RegexMatcher(".*Debug As.*")),
new WithTextMatcher(new RegexMatcher(".*"+ EXAMPLE_TEST_CLASS_NAME + ".*")));
new WithTextMatcher(new RegexMatcher(".*Debug As.*")),
new WithTextMatcher(new RegexMatcher(".*RedDeer Test.*")));
} catch (CoreLayerException exc) {
fail("ContextMenuItem Debug As -> RedDeer Test (" + EXAMPLE_TEST_CLASS_NAME + ") is missing");
fail("ContextMenuItem Debug As -> RedDeer Test is missing");
}
}

Expand Down

0 comments on commit 686ddb1

Please sign in to comment.