Fixed #14660 - Queries do not use source attribute

The gem provider takes the source attribute into account
when installing a gem but not when querying the current state
of a gem. Hence if a newer version of a gem exists in an outside
source then it is not found by the querying and hence not installed.
Worse, if a lower version of a gem exists in an external gem source
then Puppet will actually downgrade the gem.