Last modified: 2012-04-04 09:07:49 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T36141, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 34141 - Integrate Jenkins with Git
Integrate Jenkins with Git
Status: RESOLVED FIXED
Product: Wikimedia
Classification: Unclassified
Git/Gerrit (Other open bugs)
unspecified
All All
: Highest enhancement (vote)
: ---
Assigned To: Antoine "hashar" Musso (WMF)
:
Depends on: 34426 35646
Blocks: 22596
  Show dependency treegraph
 
Reported: 2012-02-01 23:52 UTC by Rob Lanphier
Modified: 2012-04-04 09:07 UTC (History)
5 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Rob Lanphier 2012-02-01 23:52:21 UTC
We would like to make sure we have post-commit integration of Jenkins with Git.  *  When a commit comes in, we'd like a post-commit hook to start tests running
*  phpUnit tests should be run
*  TestSwarm tests should be run
*  Results should be reported back to Gerrit
Comment 1 Krinkle 2012-02-02 00:17:53 UTC
> *  TestSwarm tests should be run

This one depends on the Jenkins-TestSwarm plugin, which doesn't have a stable public version yet afaik, athough WMF could contribute to that.
Comment 2 Antoine "hashar" Musso (WMF) 2012-02-10 14:42:36 UTC
>  When a commit comes in, we'd like a post-commit hook to start tests running

I have submitted a change to have gerrit send a notification to jenkins:

 https://gerrit.wikimedia.org/r/2495

The hook send the repo URL that has been modified, Jenkins git plugin should then trigger a build for any job having such URL.
Comment 3 Antoine "hashar" Musso (WMF) 2012-03-03 20:06:30 UTC
Above change (2495) might not be needed anymore. Meanwhile, I have configured Jenkins to interact with Gerrit directly.
Comment 4 Antoine "hashar" Musso (WMF) 2012-03-07 15:48:22 UTC
State as of March 7th:

Jenkins has a link established with gerrit

It does fetch any patch set submitted to test/mediawiki/core ( MediaWiki-GIT-Fetching job ).

Then two jobs, for now, are triggered:
- a job that runs databaseless tests
- a job running parser tests

Still need to be polished. The tests results are not aggregated. The notification made at the end of the build says "build started".
Comment 5 Krinkle 2012-03-08 12:22:26 UTC
I remember from an earlier conversation that it was decided that the unit test should indeed be ran before the merge, but not directly after the push for git review (for security reasons).

from memory:
* after initial review unit tests are ran (cherry pick apply to git clone) and results posted to Gerrit as review +1/-1; results from these builds by jenkins are not reported on IRC
* after the merge to master jenkins' regular (linear) project for mediawiki master picks up and runs unit tests and reports to IRC if it breaks as usual.

correct ?
Comment 6 Sumana Harihareswara 2012-03-14 23:58:28 UTC
This does not block the March 21st migration.  Thus, marking priority Normal.
Comment 7 Antoine "hashar" Musso (WMF) 2012-03-16 08:25:57 UTC
I have uploaded the Jenkins jobs rewriting to Gerrit integration/jenkins project.

Still need to polish that up but I have been busy with other things lastly.

Jenkins jobs directory on gallium is a git repo pointing to integration/jenkins so we can track changes.
Comment 8 Antoine "hashar" Musso (WMF) 2012-03-30 19:43:28 UTC
I have resumed working on Jenkins. It is polished and running again. The main fetching job is MediaWiki-GIT-Fetching : https://integration.mediawiki.org/ci/job/MediaWiki-GIT-Fetching/

There is a lot more to do, specially adding more children tests (such as linter and over tests suites) and manage to report the result of all builds back in Gerrit.
Comment 9 Mark A. Hershberger 2012-04-02 15:38:34 UTC
(In reply to comment #8)
> The main
> fetching job is MediaWiki-GIT-Fetching :
> https://integration.mediawiki.org/ci/job/MediaWiki-GIT-Fetching/

Reducing to "Normal" priority.
Comment 10 Antoine "hashar" Musso (WMF) 2012-04-02 16:06:00 UTC
I have Jenkins configured to run some tests. Still need to polish up the reporting though.

Please note that currently a faulty commit has been merged in master which causes API tests to fail (bug 35646)
Comment 11 Antoine "hashar" Musso (WMF) 2012-04-04 09:07:49 UTC
Jenkins now runs the full PHPUnit test suite whenever a patchset is submitted to Gerrit.  I am thus considering this request as implemented.

If there is anything that need to be tweaked, please open a new bug report.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links