class ChefCLI::PolicyfileCompiler

def handle_conflicting_cookbooks(conflicting_cookbooks)

def handle_conflicting_cookbooks(conflicting_cookbooks)
  # ignore any cookbooks that have a source set.
  cookbooks_wo_source = conflicting_cookbooks.select do |cookbook_name|
    location_spec = cookbook_location_spec_for(cookbook_name)
    location_spec.nil? || location_spec.source_options.empty?
  end
  if cookbooks_wo_source.empty?
    nil
  else
    raise CookbookSourceConflict.new(cookbooks_wo_source, default_source)
  end
end