Open Source RDBMS - Seamless, Scalable, Stable and Free

English | Login |Register

Import Groovy Maven Project in IntelliJ


JetBrain IntelliJ IDEA is the most excellant IDE in the Java world and a lot of open source developers are adopting it in their daily life tools. Recently nGrinder dev team switched the IDE from Eclipse to IntelliJ as well.

IntelliJ is the quite good match to nGrinder Groovy Maven project because it already includes all the plugins(Groovy, SVN, Maven) in its default package and needs very few configurations to run nGrinder test cases. Please follow the below descriptions.

  1. Install IntelliJ IDEA Community Edition (It’s free)
  2. Run IntelliJ IDEA. Enables SVN(Select VCS Integration Plugins page), Maven, Groovy supports(Slect Other Plugins Page).
  3. Select “Check out from Version Control”
    image
  4. Select the Subversion as VCS and type the SVN url in which SVN maven project is stored. Then type ID / PW.
  5. Then check out.
  6. In the imported Project, select the “Add Framework Support”
    image
  7. Select Groovy and Click OK.
    image
  8. You need to modify the pom.xml to make the test runnable in IDE. Open pom.xml and add followings.
    <profiles>
            <profile>
                <id>intellij</id>
                <dependencies>
                    <!-- the dependency to ngrinder-groovy will not be scoped as 
    provided when the intellij profile is activiated –> <dependency> <groupId>org.ngrinder</groupId> <artifactId>ngrinder-groovy</artifactId> <version>3.2.3</version> <!-- provide the appropriate version here -> </dependency> </dependencies> </profile> </profiles>
  9. Open Maven View.
    image
  10. Activate IntelliJ profile and Click “Reimport Maven Project…” on the left top of the below view.
    image
  11. Select the test groovy file and Select “Run Test” on the context menu.
    image
  12. Then you will see the following output on the Run panel. Please copy –javaagent… part
    image
  13. Click Run=>Edit Configuration Menu.
    image
  14. Change the default JUnit VM options to have the javaagent option.
    image
  15. Delete JUnit>TestRunner.test configuration.
    image
  16. Then run the step 11 again. You will see the following test output view.
    image
  17. Debug test cases and commit the code into SVN when you finished.
    image
  18. Then run this script in nGrinder!! That’s it!!



comments powered by Disqus
문서 정보
viewed 1555 times
번역 en
작성자
posted 6달 전
junoyoon
공헌자
마지막 수정시간 2달 전
변경 내역 보기
Share this article