Skip to content

Commit

Permalink
chore: disable some coverage that I don't think makes sense
Browse files Browse the repository at this point in the history
  • Loading branch information
sighphyre committed Feb 21, 2024
1 parent 9be1f29 commit 8e64f84
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/unleash/metrics_reporter.rb
Expand Up @@ -39,7 +39,9 @@ def post
if ['200', '202'].include? response.code
Unleash.logger.debug "Report sent to unleash server successfully. Server responded with http code #{response.code}"
else
# :nocov:
Unleash.logger.error "Error when sending report to unleash server. Server responded with http code #{response.code}."
# :nocov:
end
end
end
Expand Down
6 changes: 6 additions & 0 deletions lib/unleash/toggle_fetcher.rb
Expand Up @@ -91,11 +91,17 @@ def read!
backup_data = File.read(backup_file)
update_engine_state!(backup_data)
rescue IOError => e
# :nocov:
Unleash.logger.error "Unable to read the backup_file: #{e}"
# :nocov:
rescue JSON::ParserError => e
# :nocov:
Unleash.logger.error "Unable to parse JSON from existing backup_file: #{e}"
# :nocov:
rescue StandardError => e
# :nocov:
Unleash.logger.error "Unable to extract valid data from backup_file. Exception thrown: #{e}"
# :nocov:
end

def bootstrap
Expand Down
2 changes: 2 additions & 0 deletions lib/unleash/variant.rb
Expand Up @@ -12,7 +12,9 @@ def initialize(params = {})
end

def to_s
# :nocov:
"<Variant: name=#{self.name},enabled=#{self.enabled},payload=#{self.payload}>"
# :nocov:
end

def ==(other)
Expand Down

0 comments on commit 8e64f84

Please sign in to comment.