Owners of the 2012 or 2013 15-inch MacBook Pro who need their batteries replaced are in luck: due to a supply shortage of the battery parts, Apple is giving users the option to receive a new machine with "equivalent" specs instead of waiting until September for the parts. Users have reported getting 2015 or even 2017 15-inch MacBook Pros as replacements.
https://www.notebookcheck.net/Some-2012-2013-MacBook-Pro-owners-are-getting-new-machines-due-to-battery-shortage.237058.0.html