Skip to content, Skip to search


Pinpoint regressions with Git

30 bytes added, 16:26, 19 September 2015
How to bisect with Git: Update test instructions to use Maven to run unit tests
== How to find which commit introduced a regression ==
So you found a regression? I.e. you know that the version worked perfectly that you had yesterday of, say, the [[ImageJ LauncherOps]]library, but today it crashes?
Git-bisect to the rescue!
This will start the bisection process, i.e. it will try to find a revision that is as much "in the middle" between the bad commit(s) and the good commit(s) (you will mark more and more commits as good or bad in the process, and by inference, the ancestors of good commits will be considered good, and the offspring of bad commits will be considered bad, too), and let you test that.
In our case, let's just test run the Fiji launcherunit tests:
<source lang="bash">
./ fiji && ./fijimvn clean test
If the test is undecided (for example, e.g.: it does not compile at all, so you do not know if the unit test in question passes), mark it with
<source lang="bash">
Bureaucrat, emailconfirmed, incoming, administrator, uploaders