views:

51

answers:

2

Hi,

When using an automated build system, it is usually a source control entry which executes tests (but I assume this can be configured to not be on every entry in a large team). How comes build applications have actions for source code checkins. Is there any need for this? So to summarise, is a build script executed by a source control entry or at a certain time everyday?

Also, the term "break the build" - does this mean code put source control and when the build is executed, it fails due to the code not passing a unit test/code coverage app returns negative results below a certain threshold?

Finally, what does a step mean? (Eg one step build)?

Thanks

+1  A: 

Also, the term "break the build" - does this mean code put source control and when the build is executed, it fails due to the code not passing a unit test/code coverage app returns negative results below a certain threshold?

This could mean different things depending on company, project or team. Usually "build" is some reference (usually automated) procedure which is either succeeds or not. Thus "breaking the build" is doing something that leads failing of this reference procedure.

It could include or exclude unit-tests running, or regression test running, or deployment of your product, or whatever your team thinks should never fail.

Alexander Poluektov
+2  A: 

So to summarize, is a build script executed by a source control entry or at a certain time everyday?

This depends. Some teams use a commit in the version control system as trigger, some teams use a temporal event as trigger (e.g. each hour). If you run the build after each change, you get immediate feedback. If you let some time run between two builds, you delay that feedback and, in case of a build failure, it's harder to identify the change(s) that are the cause. It may require more investigation.

Just to clarify the vocabulary, for me, "the build" is actually the script/tool that automates all the things that needs to be done (compiling, runing tests, etc). Then running this automated build continuously is what people call "continuous integration". And triggering a build on an event (time based or on commit), pulling the sources from the repository, running the build script, notifying people in case of failure is the responsibility of a "continuous integration engine".

Also, the term "break the build" - does this mean code put source control and when the build is executed, it fails due to the code not passing a unit test/code coverage app returns negative results below a certain threshold?

This is very binary indeed: the build passes, or it doesn't. When it doesn't, there can be many reasons: the code didn't compile, a test failed, a quality check failed (coding standards, code coverage, etc). If you commit some code than causes a build failure (whatever the reason is), then you "broke the build".

Finally, what does a step mean? (Eg one step build)?

In my opinion, a one step build means that you can build your entire application, run the tests, run the quality checks, produce reports, assemble the application, deploy it, etc with one command. This is a synonym of automated build (if you can't run your build in one step, i.e. if it requires human intervention, then it isn't fully automated).

Pascal Thivent
What governs the criteria for a build failure? How can it be set?
blade1
@blade1 Well, things like the code compiles, the tests pass are pretty objective. But quality standards conformance is more subjective and vary from one project to the other (and tooling will be language dependent). Actually, my experience is that many projects don't have any quality standards. This doesn't mean it's a good thing, I personally believe that high quality is the key to sustainable pace on the long run.
Pascal Thivent