module OasRails::Spec::Hashable

def self.hash_representation_recursive(obj)

def self.hash_representation_recursive(obj)
  case obj
  when Hash
    obj.transform_values { |v| hash_representation_recursive(v) }
  when Array
    obj.map { |v| hash_representation_recursive(v) }
  when Hashable
    obj.hash_representation
  else
    obj
  end
end