Thanks so much for this! I was looking for a way to provide my users with a way to see exactly who will be approving their records, before actually submitting for approval.
I needed to be able to show the name of the step in addition to the number and name of approver (since sometimes a particular user can approve in different steps). So I made some significant changes, but I just wanted to say thank you and provide you with my alternate version.
I didn't need to be able to show multiple approval processes that met the entry criteria, just the one that will actually run, so I removed some of the repeat logic and just did a simulated submission and recorded the approval steps.By doing that, I was able to solve the first of your possible improvements.
The second, if you're using this in a managed package, my understanding is that as long as the test class has full coverage in your org, it doesn't matter if it has full coverage in every customer org. Generally speaking, of course, most people wouldn't need this code if they didn't have any approval processes. But that's not really a concern for me.
The third improvement was very important for me, so rather than querying the ProcessInstanceWorkItem object for the approval steps, I did a query of the ProcessInstance and a subquery to StepsAndWorkitems (which is the relationship name of ProcessInstanceHistory) to get both the name of the approver and the name of the step.
Here's my code: https://gist.github.com/AndersonKatharineTNC/6b04db1f68540c729b9fbd15ac92ec13
Here's a screenshot of how the visualforce page looks in classic:
And in Lightning Experience: