How to check if an hash is "completely" included in another hash?
The easiest way I can think of would be:
hash2.values_at(*hash1.keys) == hash1.values
That will be enough
(hash1.to_a - hash2.to_a).empty?
The easiest way I can think of would be:
hash2.values_at(*hash1.keys) == hash1.values
That will be enough
(hash1.to_a - hash2.to_a).empty?