How to use hudson tool for automation [message #1261514] |
Sun, 02 March 2014 18:09 |
Kanhaiya Agrawal Messages: 3 Registered: March 2014 |
Junior Member |
|
|
Hello there, hope you are doing well. Recently I came to know about CI server, I found Hudson is one the CI servers out.
Now, the thing is that I'm relatively new to this CI server, I have gained some knowledge about CI servers, why they are used etc, but I am having some issues.
I have installed/deployed Hudson (by java -jar hudson.war command), I am using eclipse for automation script (using Eclipse for development). Now the question is how to add my eclipse project/workspace to Hudson,a simple addition java program" in Eclipse, I want them to move to Hudson server ? How to do it ? I have created a "free style software job" but i don't know the next step .
Sorry for asking such basic questions but I am running out of time. Thanks
Please guide me to run the java project in hudson .How to config hudson for my project.
Please help me !!!!
Thanks in Advance.
|
|
|
Re: How to use hudson tool for automation [message #1261631 is a reply to message #1261514] |
Sun, 02 March 2014 21:08 |
|
Hi,
Can you precise what type of project you want to build and how you currently build it (what kind of scripts are you writing with Eclipse : Ant, Maven, ... ?). Indeed, Hudson allows you to build your project, run tests, code analyser, etc. but each step needs its own configuration. So, to begin you will have to create a free style project, and select how you want to build your project, and when (at fixed time, on SCM poolling, ...)
|
|
|
|
Re: How to use hudson tool for automation [message #1262076 is a reply to message #1261956] |
Mon, 03 March 2014 08:33 |
|
If I don't make any mistake, TestNG is similar to JUnit, so you want to use Hudson to launch your tests scripts automatically ?
The thing is that Hudson rely on other tools to compile, launch the tests etc. You must configure your project to be able to use a Maven command, an Ant command or event a .bat if you prefer. Once this is done, on your hudson build configuration, you will be able to set the build steps (call Maven, etc.). It seems that TestNG can be integrated in a Maven environment (cf. http://testng.org/doc/maven.html) and I advise you to configure your project this way.
|
|
|
|
Re: How to use hudson tool for automation [message #1262434 is a reply to message #1262154] |
Mon, 03 March 2014 16:30 |
Winston Prakash Messages: 534 Registered: August 2011 Location: Fremont, CA USA |
Senior Member |
|
|
Hi Kanhaiya, if you are new to Hudon, I would suggest you to read the free online book on Hudson or you could purchase the latest book on Hudson Continuous Integration in Practice.
Basically you have to do the following
- First set up an SCM and push your code to SCM
- Then tell Hudson (in the Job configuration) about the SCM and your repository
- Next you need to tell Hudson how often it should check you SCM to see if you have pushed new code
- Then tell Hudson what kins of build script it should execute (usually ant, maven, gradle, ivy etc). Note, it does not understand Eclipse project directly (You could use Eclipse buckminster too)
- Hudson checkout the sources from SCM and builds using your build script,
- Now after executing your project Hudson, the junit tests will be available to display
- You need to tell Hudson where to find the test results in the post build section of the job configuration
Write to me at winston DOT prakash AT gmai DOT com, if you still have trouble
Winston Prakash
Eclipse Hudson team
|
|
|
Powered by
FUDForum. Page generated in 0.02529 seconds