sanger/sequencescape

View on GitHub
lib/deployed_version.rb

Summary

Maintainability
A
0 mins
Test Coverage
A
100%

Deployed::RepoData has at least 19 methods
Open

  class RepoData
Severity: Minor
Found in lib/deployed_version.rb by reek

Too Many Methods is a special case of LargeClass.

Example

Given this configuration

TooManyMethods:
  max_methods: 3

and this code:

class TooManyMethods
  def one; end
  def two; end
  def three; end
  def four; end
end

Reek would emit the following warning:

test.rb -- 1 warning:
  [1]:TooManyMethods has at least 4 methods (TooManyMethods)

Deployed has 17 constants
Open

module Deployed
Severity: Minor
Found in lib/deployed_version.rb by reek

Too Many Constants is a special case of LargeClass.

Example

Given this configuration

TooManyConstants:
  max_constants: 3

and this code:

class TooManyConstants
  CONST_1 = :dummy
  CONST_2 = :dummy
  CONST_3 = :dummy
  CONST_4 = :dummy
end

Reek would emit the following warning:

test.rb -- 1 warnings:
  [1]:TooManyConstants has 4 constants (TooManyConstants)

Deployed has no descriptive comment
Open

module Deployed
Severity: Minor
Found in lib/deployed_version.rb by reek

Classes and modules are the units of reuse and release. It is therefore considered good practice to annotate every class and module with a brief comment outlining its responsibilities.

Example

Given

class Dummy
  # Do things...
end

Reek would emit the following warning:

test.rb -- 1 warning:
  [1]:Dummy has no descriptive comment (IrresponsibleModule)

Fixing this is simple - just an explaining comment:

# The Dummy class is responsible for ...
class Dummy
  # Do things...
end

Deployed::RepoData has no descriptive comment
Open

  class RepoData
Severity: Minor
Found in lib/deployed_version.rb by reek

Classes and modules are the units of reuse and release. It is therefore considered good practice to annotate every class and module with a brief comment outlining its responsibilities.

Example

Given

class Dummy
  # Do things...
end

Reek would emit the following warning:

test.rb -- 1 warning:
  [1]:Dummy has no descriptive comment (IrresponsibleModule)

Fixing this is simple - just an explaining comment:

# The Dummy class is responsible for ...
class Dummy
  # Do things...
end

Deployed::RepoData#read_file doesn't depend on instance state (maybe move it to another class?)
Open

    def read_file(filename)
Severity: Minor
Found in lib/deployed_version.rb by reek

A Utility Function is any instance method that has no dependency on the state of the instance.

Deployed::RepoData#execute_command doesn't depend on instance state (maybe move it to another class?)
Open

    def execute_command(cmd)
Severity: Minor
Found in lib/deployed_version.rb by reek

A Utility Function is any instance method that has no dependency on the state of the instance.

There are no issues that match your filters.

Category
Status