Do you have some opinion for code coverage in Hudson.. Now i have build with Msbuild and MSTest and that's work.
But for code coverage, i think i need some help. I have searched that somebody use nCover another with Emma. Which one is better and more easier ? And maybe reference to help me.
Best regard,
Are you .NET (NCover) or Java (Emma) or both?
NCover should work with Hudson but costs
Open Source projects exist look for PartCover and more recently OpenCover.
All three .NET tools support command-line and as such they should integrate with Hudson.
We are currently using dotCover by JetBrains. It's cheaper than NCover and it integrates well with Visual Studio. You don't have to use a separate application (NCover Explorer) to view your code with the covered/uncovered highlighting, which is great.
The command line version of dotCover allows you to create XML files of the analysis and you can parse the XML via <XmlRead> (in the MSBuild Community Tasks library) to parse the output.
It takes a while to get set up properly, but it works.
Related
I installed hybris plugin.
Imported project with it.
Have done ant clean all.
Then, if I try to build->recompile class it's not working. Seems like idea doesn't see classes generated by ant.
If I do build->rebuild project and then build->recompile class it's working fine, but it's not convenient at all. I believe there is fix to this, but I couldn't find it.
This is usual error I've got(packages are different for different cases):
this is essentially the expected behaviour. You can't mix "ant" build
and "native IDEA" build. Those are two separate build systems.
This is an explanation of hybris plugin developer (hybris-integration.atlassian.net/browse/IIPS-120)
And he suggests a solution for that:
before you try to import the project you need to do ant clean all (you will not need to use ant afterwards)
import the project using hybris plugin.
Press Build->Recompile project
Then you can create or modify your test run configuration if needed.
Recompile your classes and so on directly in Idea.
Also, he mentioned deal with JRebel here (hybris-integration.atlassian.net/browse/IIPS-47)
we support both compilation modes. Ant targets and idea internal. They
shouldn't be mixed as idea has it's own compilation model/cache. If
you use idea compilation then you can use JRebel or hotswap.
You cant hotswap classes in hybris without the help of a hotswap agent.There is a tool available in the market called JRebel. It is a good commercial tool if one can afford. However, if you are an open-sourcist, there is a promising alternative to JRebel, which is DCEVM (Dynamic Code Evolution Virtual Machine) along with HotswapAgent.
I don't know if this help,
you can start another cmd console, and run
setantenv and ant build to hotswap class in runtime.
If you used the following:
Continuous Integration using build scripts
IDE for code development
Do you run into problems of synchronizing your build scripts with the IDE build system? If so, how do you resolve this kind of issue? Using any environment (Java/.NET/etc) to explain the solution will do. I just want to get ideas on how people solve this problem.
In Java world you can have 2 kind of scripts - build scripts & scripts to generate project file for your favorite IDE (ipr for IDEA for example). Such that if you project's structure have changed just re-run the script that will update .ipr file, for example. Also, various people in the team can work with different IDEs.
In .NET world there are 2 options:
if you build with MSBuild then you don't need to synchronize anything - .csproj files from VS are valid MSBuild files as well.
if you build with NAnt you can run devenv task that will go to .sln file and still call .csproj files that are always up to date.
This is my second question on Bamboo (My First One). My understanding after reading suggested info, I need a build tool, like nAnt or MSbuild to write a script that gets the source code and builds it (I am working on a .net 3.5 with silverlight project). After, when deploying, I need to write scripts to move my files to the diff servers. Please tell me whether I am going in the right direction or not. Can I use ant, maven, bash scripts to do the same with a .net project?
Yes, that is true:
Bamboo is the central management server which coordinates all work
Bamboo itself has interfaces and plugins for lots of types of work
Bamboo basically needs to first get your source from a source repository (lots of plugins here for a variety of systems)
Then it needs to do the build - that can be done by using MSBuild to build your Visual Studio solution, or it could be a batch file to call your XYZ compiler and linker to create your app - whatever it is you have and use
Once your solution or project is built, you have "artifacts" (build results, e.g. executable app, config files, etc.) lying around
with those results, you can do additional things:
zip them up into a ZIP file and copy them somewhere
run a install builder on them and create an MSI
install them on a test server to make sure everything installs just fine
The sky's the limit! :-)
But in general: Bamboo is just the "orchestrator" - the coordinator. The actual work is done by either direct Bamboo plugins (of which there are plenty), or then you can call external command-line apps by means of a unix script or Windows batch file.
Marc
I'm imagining something like
msbuild /t:CodeplexRelease
which would build, then upload the outputs to the specified Codeplex project.
Has anyone done this?
Here's documentation on using the "CodePlex MSBuild Tasks" for creating and uploading files for a new release: http://codeplex.codeplex.com/wikipage?title=CodePlexMSBuildTasks&referringTitle=CodePlexAPI
Setting up a continuous integration server for a CodePlex project
SNAK - The Simple NAnt Acceleration Kit
Getting Continuous Integration Working With CodePlex: Part III
that should get you started.
You might be able to write a task that uses WatiN or Selenium, but as far as I know CodePlex doesn't have an API for such automated tasks.
I'm trying to use the MSBuild NUnit community task to force tests to run on each build, but I now see that when I use ReSharper's test runner and it builds the project I'm running the tests twice. It works but is not really desirable.
Does anyone know of a variable or condition I can check within MSBuild so that I can skip the community task if I know the test runner is going to execute the tests anyway?
Note: I'm using VS2008 and the MSBuild script is integrated with the solution/project files. I want the best of all worlds. CTRL + SHIFT + B, plus command-line, plus CI server.
I asked this question on the Resharper community forums and although I didn't get a direct yes or no to my question, I interpreted the answer to be no. If anyone wants to chime in with a confirmed yes or no, it would set my mind at ease.
I decided I could work around my problem by creating a solution configuration called DebugResharperTest and I choose that config when I want to use the Resharper test runner. That configuration name variable will keep the build from kicking off the NUnit msbuild task.
When building in Visual Studio MSBuild defines an extra property that you can use to disable the nUnit Task.
<NUnit Condition="'$(BuildingInsideVisualStudio)' != 'true'"
...other props
/>