Skip to content

Commit

Permalink
Update archetype dependencies
Browse files Browse the repository at this point in the history
Signed-off-by: Ondrej Dockal <odockal@redhat.com>
  • Loading branch information
odockal committed May 26, 2021
1 parent 3eb1801 commit fe0c2a6
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@
<archetype-descriptor name="eclipse.plugin.archetype">
<requiredProperties>
<requiredProperty key="tycho_version">
<defaultValue>0.26.0</defaultValue>
<defaultValue>2.2.0</defaultValue>
</requiredProperty>
<requiredProperty key="eclipse_platform">
<defaultValue>2018-12</defaultValue>
<defaultValue>2021-03</defaultValue>
</requiredProperty>
<requiredProperty key="reddeer_version">
<defaultValue>2.4.0.Final</defaultValue>
<defaultValue>3.3.0.Final</defaultValue>
</requiredProperty>
<requiredProperty key="version">
<defaultValue>1.0.0-SNAPSHOT</defaultValue>
Expand Down
2 changes: 1 addition & 1 deletion archetype/src/main/resources/archetype-resources/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
</prerequisites>

<properties>
<java.version>1.8</java.version>
<java.version>11</java.version>
<maven.version>3.5</maven.version>
<tycho.version>${tycho_version}</tycho.version>
<tycho.test.jvmArgs>-Xmx512m</tycho.test.jvmArgs>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ package=foo.bar.myplugin.simrel
version=1.0.0-SNAPSHOT
groupId=foo.bar.myplugin
artifactId=reddeer.archetype
tycho_version=1.4.0
eclipse_platform=2019-12
tycho_version=2.2.0
eclipse_platform=2021-03
reddeer_version=master
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
import org.eclipse.reddeer.eclipse.condition.ExactNumberOfProblemsExists;
import org.eclipse.reddeer.eclipse.condition.ProblemExists;
import org.eclipse.reddeer.eclipse.condition.ProblemsViewIsEmpty;
import org.eclipse.reddeer.eclipse.condition.ProjectExists;
import org.eclipse.reddeer.eclipse.jdt.ui.packageview.PackageExplorerPart;
import org.eclipse.reddeer.eclipse.jdt.ui.wizards.JavaProjectWizard;
import org.eclipse.reddeer.eclipse.jdt.ui.wizards.NewClassCreationWizard;
Expand All @@ -42,6 +43,7 @@
import org.eclipse.reddeer.eclipse.ui.markers.matcher.MarkerPathMatcher;
import org.eclipse.reddeer.eclipse.ui.markers.matcher.MarkerResourceMatcher;
import org.eclipse.reddeer.eclipse.ui.markers.matcher.MarkerTypeMatcher;
import org.eclipse.reddeer.eclipse.ui.navigator.resources.ProjectExplorer;
import org.eclipse.reddeer.eclipse.ui.problems.Problem;
import org.eclipse.reddeer.eclipse.ui.views.markers.ProblemsView;
import org.eclipse.reddeer.eclipse.ui.views.markers.QuickFixPage;
Expand All @@ -50,7 +52,10 @@
import org.eclipse.reddeer.eclipse.ui.views.markers.ProblemsView.ProblemType;
import org.eclipse.reddeer.eclipse.utils.DeleteUtils;
import org.eclipse.reddeer.junit.runner.RedDeerSuite;
import org.eclipse.reddeer.junit.screenshot.CaptureScreenshotException;
import org.eclipse.reddeer.junit.screenshot.ScreenshotCapturer;
import org.eclipse.reddeer.requirements.cleanworkspace.CleanWorkspaceRequirement.CleanWorkspace;
import org.eclipse.reddeer.requirements.closeeditors.CloseAllEditorsRequirement;
import org.eclipse.reddeer.swt.api.Shell;
import org.eclipse.reddeer.swt.condition.ShellIsAvailable;
import org.eclipse.reddeer.swt.impl.button.FinishButton;
Expand All @@ -75,8 +80,8 @@
@CleanWorkspace
public class ProblemsViewTest {

private PackageExplorerPart pkgExplorer;
private ProblemsView problemsView;
private ProjectExplorer prjExplorer;
private ProblemsView problemsView;

private static final String JAVA_PROBLEM = "Java Problem";
private static final String PROJECT_NAME = "ProblemsViewTestProject";
Expand All @@ -91,22 +96,28 @@ public class ProblemsViewTest {

@Before
public void setUp() {
problemsView = new ProblemsView();
problemsView.open();
prjExplorer = new ProjectExplorer();
prjExplorer.open();
if (prjExplorer.containsProject(PROJECT_NAME)) {
// DeleteUtils.forceProjectDeletion(prjExplorer.getProject(PROJECT_NAME), true);
prjExplorer.getProject(PROJECT_NAME).delete(true);
}
JavaProjectWizard dialog = new JavaProjectWizard();
dialog.open();
NewJavaProjectWizardPageOne page1 = new NewJavaProjectWizardPageOne(dialog);
page1.setProjectName(PROJECT_NAME);
dialog.finish();
problemsView = new ProblemsView();
problemsView.open();
pkgExplorer = new PackageExplorerPart();
pkgExplorer.open();
dialog.finish(TimePeriod.LONG, false, null);
new WaitUntil(new ProjectExists(PROJECT_NAME), TimePeriod.DEFAULT, false);
}

@After
public void tearDown() {
problemsView.showDefaultProblemColumns();
pkgExplorer.open();
DeleteUtils.forceProjectDeletion(pkgExplorer.getProject(PROJECT_NAME),true);
prjExplorer.open();
// DeleteUtils.forceProjectDeletion(prjExplorer.getProject(PROJECT_NAME),true);
prjExplorer.getProject(PROJECT_NAME).delete(true);
}

@Test
Expand Down Expand Up @@ -185,7 +196,7 @@ public void testHideHiddenProblemColumn() {

@Test
public void testGetProblemColumns() {
pkgExplorer.open();
prjExplorer.open();
createError();
List<String> foundColumns = problemsView.getProblemColumns();
List<String> requiredColumns = new ArrayList<String>(Arrays.asList(
Expand Down Expand Up @@ -374,8 +385,8 @@ public void testProblemQuickfix(){

@Test
public void testProblemQuickfixWithNewDialog(){
pkgExplorer.open();
pkgExplorer.getProject(PROJECT_NAME).getProjectItem("src").select();
prjExplorer.open();
prjExplorer.getProject(PROJECT_NAME).getProjectItem("src").select();
NewClassCreationWizard newJavaClassDialog =
new NewClassCreationWizard();
newJavaClassDialog.open();
Expand Down Expand Up @@ -409,8 +420,8 @@ private void createWarning() {
}

private void createProblem(boolean error, final String newClassName) {
pkgExplorer.open();
pkgExplorer.getProject(PROJECT_NAME).getProjectItem("src").select();
prjExplorer.open();
prjExplorer.getProject(PROJECT_NAME).getProjectItem("src").select();
NewClassCreationWizard newJavaClassDialog =
new NewClassCreationWizard();
newJavaClassDialog.open();
Expand Down

0 comments on commit fe0c2a6

Please sign in to comment.