Skip to content
This repository was archived by the owner on Jul 14, 2021. It is now read-only.

Remove Foodcritic tests / Foodcritic from the readme #2639

Merged
merged 2 commits into from
Dec 31, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions .expeditor/verify.pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,6 @@ steps:
docker:
image: ruby:2.6-buster

- label: foodcritic-generator-cb-tests-ruby-2.6
command:
- .expeditor/run_linux_tests.sh "rake style:foodcritic"
expeditor:
executor:
docker:
image: ruby:2.6-buster

- label: cookstyle-generator-cb-tests-ruby-2.6
command:
- .expeditor/run_linux_tests.sh "rake style:cookstyle"
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@
ChefDK brings Chef Infra Client and the development tools developed by the Chef Community together and acts as the consistent interface to this awesomeness. This awesomeness is composed of:

* [Chef Infra Client][]
* [Berkshelf][]
* [Chef InSpec][]
* [Test Kitchen][]
* [ChefSpec][]
* [Foodcritic][]
* [Cookstyle][]
* [Delivery CLI][]
* [Push Jobs Client][]
* [Berkshelf][]

This repository contains the code for the `chef` command. The full
package is built with omnibus. Project and component build definitions
Expand All @@ -43,7 +43,7 @@ system bin directory, ready to use.
The following commands will download the latest ChefDK package from the `current` channel. The `current` channel holds builds that have passed testing and are candidates for release.
More information about flags supported by install.sh available here: https://docs.chef.io/api_omnitruck.html

#### Linux and OS/X:
#### Linux and macOS

In a terminal, run:

Expand Down Expand Up @@ -313,11 +313,11 @@ packaging, and building works.

[Berkshelf]: https://docs.chef.io/berkshelf.html "Berkshelf"
[Chef Infra Client]: https://www.chef.io/products/chef-infra/ "Chef Infra Client"
[Chef InSpec]: https://www.inspec.io/ "Chef InSpec"
[ChefDK]: https://downloads.chef.io/chefdk/ "ChefDK"
[Chef Documentation]: https://docs.chef.io "Chef Documentation"
[ChefSpec]: http://chefspec.github.io/chefspec/ "ChefSpec"
[Cookstyle]: https://docs.chef.io/cookstyle.html "Cookstyle"
[Foodcritic]: http://foodcritic.io "Foodcritic"
[Learn Chef]: https://learn.chef.io "Learn Chef"
[Test Kitchen]: http://kitchen.ci "Test Kitchen"
[Delivery CLI]: https://docs.chef.io/delivery_cli.html "Delivery CLI"
Expand Down
18 changes: 1 addition & 17 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ namespace :style do
spec/unit/fixtures/local_path_cookbooks
})

desc "Run Chef Ruby style checks"
desc "Run Cookstyle style checks"
RuboCop::RakeTask.new(:chefstyle) do |t|
t.requires = ["chefstyle"]
t.patterns = `rubocop --list-target-files`.split("\n").reject { |f| f =~ ignore_dirs }
Expand All @@ -58,20 +58,4 @@ namespace :style do
rescue LoadError => e
puts ">>> Gem load error: #{e}, omitting #{task.name}" unless ENV["CI"]
end

begin
require "foodcritic"

desc "Run Chef Cookbook (Foodcritic) style checks"
FoodCritic::Rake::LintTask.new(:foodcritic) do |t|
t.options = {
fail_tags: ["any"],
tags: ["~FC071", "~supermarket", "~FC031"],
cookbook_paths: ["lib/chef-dk/skeletons/code_generator"],
progress: true,
}
end
rescue LoadError => e
puts ">>> Gem load error: #{e}, omitting #{task.name}" unless ENV["CI"]
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ delivery review

## FAQ

### Why don't I just run rspec and foodcritic/rubocop on my local system?
### Why don't I just run rspec and cookstyle/chefspec on my local system?

An objection to the Test Kitchen approach is that it is much faster to run the unit, lint, and syntax commands for the project on the local system. That is totally true, and also totally valid. Do that for the really fast feedback loop. However, the dance we do with Test Kitchen brings a much higher degree of confidence in the changes we're making, that everything will run on the build nodes in Chef Workflow. We strongly encourage this approach before actually pushing the changes to Workflow.

Expand Down