puppetlabs / puppetlabs-satellite_pe_tools

Other
2 stars 15 forks source link

(MODULES-10120) enable simplecov; update to PDK 1.14.1; minor cleanups #119

Closed DavidS closed 4 years ago

DavidS commented 4 years ago

This PR was created using this script in stages running pdk update and committing individual changes in multiple iterations. Some manual fixes interspersed to reduce aberrations.

#! /usr/bin/ruby
require 'yaml'

contents = YAML.load(File.read(".sync.yml"))

contents[".gitlab-ci.yml"] = {'delete' => true}
contents["spec/spec_helper.rb"] ||= {}
contents["spec/spec_helper.rb"]['coverage_report'] = true

gitignore = contents[".gitignore"] ||= {}
gitignore["required"] ||= []
gitignore["required"] -= ["---.project"]
gitignore.delete("required") if gitignore["required"].empty?
contents.delete(".gitignore") if contents[".gitignore"].empty?

contents.delete("spec/default_facts.yml") if contents["spec/default_facts.yml"] == {"unmanaged" => true}

[".travis.yml", "appveyor.yml"].each do |f|
  contents[f] ||= {}
  if contents[f]["unmanaged"] != true && contents[f]["delete"] != true
    contents[f]["simplecov"] = true
  end
end

contents = Hash[contents.keys.sort{|a,b| a.upcase <=> b.upcase}.map{|k| [k, contents[k]]}]
File.open(".sync.yml", "w") { |file| file.write(contents.to_yaml(line_width: 200)) }
codecov-io commented 4 years ago

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@64ae998). Click here to learn what that means. The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             master   #119   +/-   ##
=======================================
  Coverage          ?     0%           
=======================================
  Files             ?      5           
  Lines             ?    206           
  Branches          ?      0           
=======================================
  Hits              ?      0           
  Misses            ?    206           
  Partials          ?      0

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 64ae998...b9c7db7. Read the comment docs.