fix bug handling enumerations

This pull request fixes a ROOT 6 specific bug in CMSSW code handling enumerations.  This code is ROOT6 specific.
This pull request fixes errors in two framework unit tests, one of which now passes, and the other of which now fails later for a different reason that still needs to be investigated.