cloudamatic/mu

View on GitHub
bin/mu-gen-docs

Summary

Maintainability
Test Coverage

Unused block argument - cfg. If it's necessary, use _ or _cfg as an argument name to indicate that it won't be used.
Open

    MU::Cloud.resource_types.each_pair { |type, cfg|
Severity: Minor
Found in bin/mu-gen-docs by rubocop

This cop checks for unused block arguments.

Example:

# bad

do_something do |used, unused|
  puts used
end

do_something do |bar|
  puts :foo
end

define_method(:foo) do |bar|
  puts :baz
end

Example:

#good

do_something do |used, _unused|
  puts used
end

do_something do
  puts :foo
end

define_method(:foo) do |_bar|
  puts :baz
end

Do not suppress exceptions.
Open

        rescue MU::Cloud::MuCloudResourceNotImplemented
Severity: Minor
Found in bin/mu-gen-docs by rubocop

This cop checks for rescue blocks with no body.

Example:

# bad

def some_method
  do_something
rescue
  # do nothing
end

Example:

# bad

begin
  do_something
rescue
  # do nothing
end

Example:

# good

def some_method
  do_something
rescue
  handle_exception
end

Example:

# good

begin
  do_something
rescue
  handle_exception
end

Use meaningful heredoc delimiters.
Open

EOF
Severity: Minor
Found in bin/mu-gen-docs by rubocop

This cop checks that your heredocs are using meaningful delimiters. By default it disallows END and EO*, and can be configured through blacklisting additional delimiters.

Example:

# good
<<-SQL
  SELECT * FROM foo
SQL

# bad
<<-END
  SELECT * FROM foo
END

# bad
<<-EOS
  SELECT * FROM foo
EOS

Redundant use of Object#to_s in interpolation.
Open

    readme += "<tr><td><strong>{MU::Config::BasketofKittens::#{MU::Cloud.resource_types[type][:cfg_plural]} #{type.to_s}}</strong></td>"
Severity: Minor
Found in bin/mu-gen-docs by rubocop

This cop checks for string conversion in string interpolation, which is redundant.

Example:

# bad

"result is #{something.to_s}"

Example:

# good

"result is #{something}"

There are no issues that match your filters.

Category
Status