[JENKINS-16394] refactored callable to compare the revisions into a named class and added regression test that it's serializable