From c4ea27a9b87e04576dec3977ad1293a2721b8e78 Mon Sep 17 00:00:00 2001 From: Scott Nelson Windels Date: Mon, 16 Jan 2017 11:13:24 -0800 Subject: [PATCH] Rubocop fixes --- Rakefile | 1 + attributes/default.rb | 1 + libraries/version.rb | 1 + metadata.rb | 1 + recipes/_service.rb | 1 + recipes/apache.rb | 1 + recipes/default.rb | 1 + recipes/kibana3.rb | 1 + recipes/kibana4.rb | 1 + recipes/nginx.rb | 1 + spec/support/matchers.rb | 1 + test/integration/kibana3_apache/serverspec/default_spec.rb | 1 + test/integration/kibana3_apache/serverspec/spec_helper.rb | 1 + test/integration/kibana3_nginx/serverspec/default_spec.rb | 1 + test/integration/kibana3_nginx/serverspec/spec_helper.rb | 1 + test/integration/kibana3_source/serverspec/default_spec.rb | 1 + test/integration/kibana3_source/serverspec/spec_helper.rb | 1 + test/integration/kibana4_apache/serverspec/default_spec.rb | 1 + test/integration/kibana4_apache/serverspec/spec_helper.rb | 1 + test/integration/kibana4_nginx/serverspec/default_spec.rb | 1 + test/integration/kibana4_nginx/serverspec/spec_helper.rb | 1 + test/unit/spec/_service_spec.rb | 1 + test/unit/spec/apache_spec.rb | 1 + test/unit/spec/default_spec.rb | 1 + test/unit/spec/kibana3_spec.rb | 1 + test/unit/spec/kibana4_spec.rb | 1 + test/unit/spec/nginx_spec.rb | 1 + test/unit/spec/spec_helper.rb | 4 ++-- 28 files changed, 29 insertions(+), 2 deletions(-) diff --git a/Rakefile b/Rakefile index 5206348..72617a9 100644 --- a/Rakefile +++ b/Rakefile @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true require 'rake' require 'rake/testtask' diff --git a/attributes/default.rb b/attributes/default.rb index fbe3043..e272b94 100644 --- a/attributes/default.rb +++ b/attributes/default.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true #<> Kibana major version default['kibana']['version'] = '3' diff --git a/libraries/version.rb b/libraries/version.rb index d8768b8..ca0eda8 100644 --- a/libraries/version.rb +++ b/libraries/version.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true class Kibana # All to find correct url to download kibana diff --git a/metadata.rb b/metadata.rb index 297fad0..55898f2 100644 --- a/metadata.rb +++ b/metadata.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true name 'kibana' maintainer 'Peter Donald' diff --git a/recipes/_service.rb b/recipes/_service.rb index 00e4a06..e9716a4 100644 --- a/recipes/_service.rb +++ b/recipes/_service.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true template node['kibana']['service']['template_file'] do cookbook node['kibana']['service']['cookbook'] diff --git a/recipes/apache.rb b/recipes/apache.rb index c587531..46d150d 100644 --- a/recipes/apache.rb +++ b/recipes/apache.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true =begin #< diff --git a/recipes/default.rb b/recipes/default.rb index 121964c..75e3f1d 100644 --- a/recipes/default.rb +++ b/recipes/default.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true =begin #< diff --git a/recipes/kibana3.rb b/recipes/kibana3.rb index 4e9d69e..fd8aa6f 100644 --- a/recipes/kibana3.rb +++ b/recipes/kibana3.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true include_recipe 'kibana' diff --git a/recipes/kibana4.rb b/recipes/kibana4.rb index ac6f83b..2731641 100644 --- a/recipes/kibana4.rb +++ b/recipes/kibana4.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true include_recipe 'kibana' diff --git a/recipes/nginx.rb b/recipes/nginx.rb index 53d0f76..9e7e625 100644 --- a/recipes/nginx.rb +++ b/recipes/nginx.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true include_recipe 'chef_nginx' template File.join(node['nginx']['dir'], 'sites-available', 'kibana') do diff --git a/spec/support/matchers.rb b/spec/support/matchers.rb index 4270f30..c7907f0 100644 --- a/spec/support/matchers.rb +++ b/spec/support/matchers.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true # matcher for install_ark def install_ark(resource_name) ChefSpec::Matchers::ResourceMatcher.new(:ark, :install, resource_name) diff --git a/test/integration/kibana3_apache/serverspec/default_spec.rb b/test/integration/kibana3_apache/serverspec/default_spec.rb index 3fda898..db8e2cb 100644 --- a/test/integration/kibana3_apache/serverspec/default_spec.rb +++ b/test/integration/kibana3_apache/serverspec/default_spec.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true require 'spec_helper' describe 'kibana' do diff --git a/test/integration/kibana3_apache/serverspec/spec_helper.rb b/test/integration/kibana3_apache/serverspec/spec_helper.rb index e521d78..be8d94d 100644 --- a/test/integration/kibana3_apache/serverspec/spec_helper.rb +++ b/test/integration/kibana3_apache/serverspec/spec_helper.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true require 'serverspec' # Required by serverspec diff --git a/test/integration/kibana3_nginx/serverspec/default_spec.rb b/test/integration/kibana3_nginx/serverspec/default_spec.rb index ff62a04..bac028a 100644 --- a/test/integration/kibana3_nginx/serverspec/default_spec.rb +++ b/test/integration/kibana3_nginx/serverspec/default_spec.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true require 'spec_helper' describe 'kibana' do diff --git a/test/integration/kibana3_nginx/serverspec/spec_helper.rb b/test/integration/kibana3_nginx/serverspec/spec_helper.rb index e521d78..be8d94d 100644 --- a/test/integration/kibana3_nginx/serverspec/spec_helper.rb +++ b/test/integration/kibana3_nginx/serverspec/spec_helper.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true require 'serverspec' # Required by serverspec diff --git a/test/integration/kibana3_source/serverspec/default_spec.rb b/test/integration/kibana3_source/serverspec/default_spec.rb index 59f977a..7846844 100644 --- a/test/integration/kibana3_source/serverspec/default_spec.rb +++ b/test/integration/kibana3_source/serverspec/default_spec.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true require 'spec_helper' describe 'kibana' do diff --git a/test/integration/kibana3_source/serverspec/spec_helper.rb b/test/integration/kibana3_source/serverspec/spec_helper.rb index e521d78..be8d94d 100644 --- a/test/integration/kibana3_source/serverspec/spec_helper.rb +++ b/test/integration/kibana3_source/serverspec/spec_helper.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true require 'serverspec' # Required by serverspec diff --git a/test/integration/kibana4_apache/serverspec/default_spec.rb b/test/integration/kibana4_apache/serverspec/default_spec.rb index b7a3c2b..51e84f8 100644 --- a/test/integration/kibana4_apache/serverspec/default_spec.rb +++ b/test/integration/kibana4_apache/serverspec/default_spec.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true require 'spec_helper' describe 'kibana' do diff --git a/test/integration/kibana4_apache/serverspec/spec_helper.rb b/test/integration/kibana4_apache/serverspec/spec_helper.rb index e521d78..be8d94d 100644 --- a/test/integration/kibana4_apache/serverspec/spec_helper.rb +++ b/test/integration/kibana4_apache/serverspec/spec_helper.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true require 'serverspec' # Required by serverspec diff --git a/test/integration/kibana4_nginx/serverspec/default_spec.rb b/test/integration/kibana4_nginx/serverspec/default_spec.rb index 7bb25df..21964d2 100644 --- a/test/integration/kibana4_nginx/serverspec/default_spec.rb +++ b/test/integration/kibana4_nginx/serverspec/default_spec.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true require 'spec_helper' describe 'kibana' do diff --git a/test/integration/kibana4_nginx/serverspec/spec_helper.rb b/test/integration/kibana4_nginx/serverspec/spec_helper.rb index e521d78..be8d94d 100644 --- a/test/integration/kibana4_nginx/serverspec/spec_helper.rb +++ b/test/integration/kibana4_nginx/serverspec/spec_helper.rb @@ -1,4 +1,5 @@ # Encoding: utf-8 +# frozen_string_literal: true require 'serverspec' # Required by serverspec diff --git a/test/unit/spec/_service_spec.rb b/test/unit/spec/_service_spec.rb index 1545818..70ad269 100644 --- a/test/unit/spec/_service_spec.rb +++ b/test/unit/spec/_service_spec.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require 'chefspec' require_relative 'spec_helper' diff --git a/test/unit/spec/apache_spec.rb b/test/unit/spec/apache_spec.rb index 721cc53..60ded7b 100644 --- a/test/unit/spec/apache_spec.rb +++ b/test/unit/spec/apache_spec.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require 'chefspec' require_relative 'spec_helper' diff --git a/test/unit/spec/default_spec.rb b/test/unit/spec/default_spec.rb index 20a3c9f..c37acca 100644 --- a/test/unit/spec/default_spec.rb +++ b/test/unit/spec/default_spec.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require 'chefspec' require_relative 'spec_helper' diff --git a/test/unit/spec/kibana3_spec.rb b/test/unit/spec/kibana3_spec.rb index 68529ff..d3b5b66 100644 --- a/test/unit/spec/kibana3_spec.rb +++ b/test/unit/spec/kibana3_spec.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require 'chefspec' require_relative 'spec_helper' diff --git a/test/unit/spec/kibana4_spec.rb b/test/unit/spec/kibana4_spec.rb index ca76fa9..518e56e 100644 --- a/test/unit/spec/kibana4_spec.rb +++ b/test/unit/spec/kibana4_spec.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require 'chefspec' require_relative 'spec_helper' diff --git a/test/unit/spec/nginx_spec.rb b/test/unit/spec/nginx_spec.rb index fcf5e12..1f08c04 100644 --- a/test/unit/spec/nginx_spec.rb +++ b/test/unit/spec/nginx_spec.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: true require 'chefspec' require_relative 'spec_helper' diff --git a/test/unit/spec/spec_helper.rb b/test/unit/spec/spec_helper.rb index 05db030..add724f 100644 --- a/test/unit/spec/spec_helper.rb +++ b/test/unit/spec/spec_helper.rb @@ -1,4 +1,5 @@ # encoding: UTF-8 +# frozen_string_literal: true # -*- mode: ruby -*- # vi: set ft=ruby : @@ -27,7 +28,6 @@ version: '7.0' }.freeze -def stub_resources -end +def stub_resources; end at_exit { ChefSpec::Coverage.report! }