Git hosting setup that pulls developers away from abandoned broken commits?

Development teams often suffer from crashes in version control. All team productivity can stop trying to recover from an assembly broken by one person.

Is there any software that allows you to host Git in such a way as to prevent build disruption in version control without accepting commits that do not pass tests in the first place? For example, a use case might look like this:

  • The software runs on a server that constantly pulls revisions from the Git repositories that the developers published.
  • For each verified revision, the software creates an audit and tests if it passes unit tests.
    • If it passes the tests, the audit merges into a “stable” branch.
    • If it does not pass the tests, it is rejected, and the audit is not merged into a “stable” branch. The developer is forced to fix the revision and resubmit it.
  • Developers, by default, extract from a “stable” branch, which should never be broken - in the sense that the tests do not fail - and are more productive, since they spend less time blocking broken assemblies. And the usefulness of such a system grows with the size of the team.

A few notes:

  • Git pre-commit hooks and the like in this case are not satisfactory. The solution must be automatic and forced on the server side for each commit.
  • We are looking for a solution that has been implemented and thought out as much as possible, instead of writing such a system from scratch.
+7
git version-control unit-testing build-automation
source share
3 answers

I think this is more of a build server function related to VCS, like Git. TeamCity has support for this, but I have not tried it, so I can’t comment on how good it really is.

http://www.jetbrains.com/teamcity/features/delayed_commit.html

Hudson guys have been discussing this for a while, but I haven't seen it in the release yet.

http://wiki.hudson-ci.org/display/HUDSON/Designing+pre-tested+commit

+1
source share

We use gerrit and hudson. This is what android and Cyanogenmod use (along with many others). A.

Gerrit allows you to verify the code and automatically build each commit with automatic rejection of those that fail.

Hudson runs the tests.

Hudson: http://wiki.hudson-ci.org/display/HUDSON/Designing+pre-tested+commit

Gerrit: http://gerrit.googlecode.com

This system works well with the repo tool to have a large number of small repositories, this will reduce merge conflicts that need to be processed manually through rebase.

Note. It is quite a bit of work to get up and running if you have a large existing code base, but it is completely worth it.

+1
source share

This is a really good idea. Bamboo supports this quite naturally. Several Bamboo customers, as well as teams at Atlassian, have this exact methodology and work with great effect. Bamboo has event listeners that can report (without polling) when the commit is transferred to the "test verfication" repository, and then test it by running tests before moving on to the stable branch. www.atlassian.com/bamboo

0
source share

All Articles