I am new to automation. Im facing this problem while running cucumber feature. It doesnt show run as Cucumber feature option at all
Screen shot of Run as options in eclipse
As, when you open a feature file in Eclipse and right-click, then you do not find an option 'Run As->Cucumber Feature', it appears that your Eclipse do not have the required Cucumber Eclipse Plug-in. You can install this plug-in using following steps:
Launch Eclipse and navigate to 'Help->Install New Software'.
Click on 'Add' button
Enter any name e.g. 'Cucumber' and type 'http://cucumber.github.com/cucumber-eclipse/update-site' as location.
Click on OK.
'Cucumber Eclipse Plugin' option will appear in the available software list.
Select the check box against it and click on 'Next' button.
Read the terms of license agreement and click on 'I accept the terms of the license agreement” if you agree with the license terms.
Click on 'Finish' button.
Let it install, it will take few seconds to complete.
After successful installation of this plug-in, if you open any feature file (i.e. file with .feature extension) and right-click, you should see 'Run As->Cucumber Feature' option.
Update 1
In Eclipse, go to 'Windows->Preferences->Run/Debug/Launching/Launch Configuration' and uncheck 'Cucumber Feature' checkbox if it is checked. Refer to below screen shot for more details:
If it is a maven project make sure you have included it as a dependency.
If you are running it as automation it would be a good idea to set it up as a maven project.
It's hard from your brief description, but if you are seeing the 'Run as Cucumber Feature' but it isn't doing anything, I had to open up the feature, right click on the white space in it, and then run as Cucumber Feature there. For some reason that worked for me.
Related
I am new to Java
I have been trying to compile my open source application
with provided steps
Import Project from Maven
1. Start IntelliJ IDEa.
2. In the "Quick Start" menu, select "Import Project".
This will open a "Select File or Directory to Import" dialog.
3. Browse to your local cTakes repository root directory and select the pom.xml file.
4. Click "Ok".
This will open an "Import Project from Maven" dialog.
5. Make sure the "Search for projects recursively" box is selected, just in case any cTakes modules are not in the pom.
6. Make sure that "Create IntelliJ IDEa modules for aggregator projects" is not selected.
If you plan to add new module, 'disable' a present cTakes module or make other changes to the main pom.xml, check the "Import Maven projects automatically" box.
See also: http://www.jetbrains.com/idea/webhelp/maven-importing.html
7. Make sure that "Create module rgoups for multi-module Maven projects" is not selected.
8. Make sure that "Keep source and test folders on reimport is selected.
9. Make sure that "Exclude build directory (%PROJECT_ROOT%/target)" is selected.
10. Make sure that "Use Maven output directories" is selected.
11. Make sure that the "Generated sources folders" option "Detect automatically" is selected.
12. For the "Phase to be used for folders update" the default option "process-resources" should be fine.
13. For the "Automatically download" options, you may select what you like, but be wary that if broken code has been checked in you may need to revert manually.
14. The default "Dependency types" are fine.
15. Click "Environment settings...".
This will open a dialog that can be used to set options about the Maven environment.
16. The default maven environment settings should be fine. If $M2_HOME is not set in your environment you may select a "Maven home directory", but it is better to set $M2_HOME in your environment.
17. Click "Next".
This will inspect the cTakes Maven settings and search for profiles. It should display a dialog with the possible cTakes profiles.
If you plan to run the UIMA CVD or CPE then select the appropriate profile. Neither is necessary
18. Click "Next".
This will open an "Import" dialog with the current version of cTakes displayed.
19. Click "Next".
This will open a dialog allowing you to select a Java SDK version.
20. Click the "+" button in the top left.
This will display a drop-down box with options for an SDK.
21. Select "JDK".
This will open a dialog to select a Java JDK directory.
22. Navigate to a directory with a JDK version 1.8 or later and click "Ok".
This will display a listing of the file paths associated with the selected JDK.
23. Click "Next".
24. Click "Ok/Next"
The project will load. This may take a while.
25. Important: If you are asked about adding any .iml files to svn, click "No".
26. You should now see the full cTakes project structure in IntelliJ.
I get everything up to step 4
but step 5 does not exist in my case
I mean in step 5
5. Make sure the "Search for projects recursively" box is selected, just in case any cTakes modules are not in the pom.
There are no options I get, it immediately takes me to the IntelliJ project
I get this screen
after I ckick finish , it takes me to this
Am I using older version? or doing something wrong?
How to get the Maven options as the instructions suggested?
It appears that you're in a unique position where the import and the recursive scanning of projects has Just Worked™ for your use case.
Given that IntelliJ IDEA 2019.3 came out at the end of November 2019 and I'm not reasonably convinced that those instructions were written or revised between the end of November and now, it could easily be the case that the instructions you've seen are out of date.
The big thing to be sure of is that your subprojects also build. On the right-hand side there, you have a list of Maven projects. Any one of those should be subprojects. Be sure that any Maven build command (e.g. mvn clean install) executes in the context of that subproject.
I have problem loading open source application
I have followed these steps
Perform a fresh checkout from SVN
1. Start IntelliJ IDEa.
2.In the "Quick Start" menu, select "Check out from Version Control".
This will display a drop-down box.
3.In the drop-down box, select "Subversion".
This will open a "Checkout from Subversion" dialog.
4.In the "Checkout from Subversion" dialog, click the "+" button in the top left to add a new Repository.
This will open a "New Repository Location" dialog.
5.In the "New Repository Location" dialog, enter the svn checkout location of cTakes.
Click "Ok".
This will inspect the repository.
6.Click the "Expand" triangle.
This should display the directory listing of trunk.
Click "Checkout".
This will open a "Destination Directory" dialog.
Enter a local directory in which to keep trunk (your sandbox).
Click "Ok". This will open a "Checkout Options" dialog.
The default options ("Head", etc.) are fine for most users.
Click "Ok".
This will open a "Working Copy Format" dialog.
Select a (version) format and click "Ok". I use version 1.8, but any should be fine.
This will start the actual checkout and display a progress dialog. The checkout may take a little while.
After the checkout has completed, a new dialog will ask you if you'd like to open the project. Click "No".
but when i reach step 5, i enter svn location
and get this error
Cannot run program "svn" (in directory "C:\Program
Files\JetBrains\IntelliJ IDEA Community Edition 2019.3"):
CreateProcess error=2, The system cannot find the file specified
note this is my first time to use Java
How can I load my application and make run successfully?
From jetbrains official blog:
... it is now required to use a command-line svn client for integration
with Subversion.
In 2018.1 the SVNKit library has been removed from the IntelliJ
platform, resulting in the above changes.
also it seems there is no plugin for svn client in marketplace.
so you should install svn command line as suggested here
IntelliJ IDEA comes bundled with the Subversion plugin. Apart from it,
you also need to download and install the command line client on your
machine.
Developing a Maven project in Eclipse, when I click the launch button, the launch will often fail with the error:
'Launching project_name' has encountered a problem.
No selected resource
This is because I have not selected a Java class file in the editor before clicking the Launch button (little green play icon).
Usually, I have the maven console, or Git staging view in focus at the time I press the button, so I understand why it is happening, just not how to prevent it.
Surely the play button knows which project to select. Why should it care which view has focus when I press the button? The launch configuration refers to the project via a value like ${project_loc:project_name} in the Base directory field.
Is there a way I can tell Eclipse to just run the maven build, regardless of what focus the IDE has?
I am running Eclipse IDE for Enterprise Java Developers.
Version: 2018-12 (4.10.0) on Ubuntu.
In Window > Preferences: Run/Debug > Launching choose Always launch the previously launched application as Launch Operation.
Make also sure not to use selection based variables like ${git_branch} without an argument.
To make git_branch independent of the selection, specify the resource (file or folder) from which you want to have the current branch name. For example, ${git_branch:/my_project}.
I have generated a demo popup menu plugin project automatically by Eclipse. Here is the project structure,
I have set a objectContribution to the point org.eclipse.ui.popupMenus,
When I right click the project and choose Run as -> Eclipse Application, another Eclipse process run and I can see the configured menu works well,
How can I install this plugin for my original Eclipse process?
What I have tried
I did some research and tried to Export -> Deployable plug-ins and fragments, then put it into the %EclipseFolder%/plugins, but it didn't work. I also have tried to Export -> Deployable features and installed it by Help->Install New Software, also failed to see the menu when right click the project.
Will you please help? BTW, I would like to know how to contribute a menu which will display when I right click on a package in a project? Thanks so much.
Use the Deployable plug-ins and fragments wizard and select Intall into Host on the Destination page.
This will create a p2 repository at the denoted location and install the selected plug-ins from there into the host instance, i.e. the Eclipse IDE that you are currently working with. I think a restart may be required.
I was trying to configure PMD plugin in eclipse (window8) but after 50% progress error occures .
i am using this in path http://sourceforge.net/projects/pmd/files/pmd-eclipse/update-site/
I need to configure PMD for code review, from some resource's i found pmd useful.
and it is good code analyzer.
If you are new to the Eclipse IDE, it's better to know how to install the plugin for it:
Start the Eclipse IDE (screenshot from the Eclipse Java EE IDE for Web Developers, version: Helios Service Release 2)
Select the Help –>Install New Software.... in the Eclipse menu item.
The install window will be open. On there, click the "Add.." button.
In the "Add Repository" window, enter the name and location (plugin URL)
PMD plugin: http://pmd.sf.net/eclipse
Then click the "OK" button.
Select PMD for Eclipse 3 and Apache Xerces in the "Select the features to install" list and click Next. Accept the terms of the license agreements and click Next.
Verify that the install location in Eclipse installation directory, otherwise select the correct one, then click Finish.
Unable to read repository problem can come because of your internet connection or proxy.
Check if eclipse update is working.
As per your screenshots you are doing fine.
Also double check your PMD url by opening it in browser.
PMD Installation
To install the PMD for Eclipse plugin:-
In Eclipse, click on
Help -> Install New Software...
Click on Add..
Enter the following:
Name: PMD for Eclipse Update Site
URL: https://sourceforge.net/projects/pmd/files/pmd-eclipse/update-site/
and click OK.
You should see PMD for Eclipse Select the checkbox next to it and
click Next
You'll need to accept the license and confirm you want to install a plugin that is not digitally signed.
Restart eclipse.