Issue #2374331 by djdevin: Write tests for 4.x -> 5.x upgrade.