Skip to content

Commit

Permalink
Increase coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
azimux committed Apr 11, 2024
1 parent d561a78 commit 9926c3b
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 8 deletions.
3 changes: 0 additions & 3 deletions src/foobara/remote_command.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,6 @@ def subclass(
possible_error.prepend_path!(path)

register_possible_error_class(possible_error)
rescue => e
binding.pry
raise
end

klass
Expand Down
3 changes: 0 additions & 3 deletions src/foobara/remote_imports/import_base.rb
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,6 @@ def load_manifest
end

def load_manifest_from_url
# TODO: introduce VCR to test the following elsif block
# :nocov:
url = URI.parse(manifest_url)
response = Net::HTTP.get_response(url)

Expand All @@ -111,7 +109,6 @@ def load_manifest_from_url
end

JSON.parse(manifest_json)
# :nocov:
end

# TODO: feels like a command smell to pass manifests here... reconsider algorithm
Expand Down
2 changes: 1 addition & 1 deletion src/foobara/remote_imports/import_command.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def import_object_from_manifest

Util.make_class_p(manifest_to_import.reference, RemoteCommand)

manifest_to_import.types_depended_on do |type|
manifest_to_import.types_depended_on.each do |type|
run_subcommand!(
ImportType,
raw_manifest: manifest_data,
Expand Down
4 changes: 3 additions & 1 deletion src/foobara/remote_imports/import_error.rb
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def import_object_from_manifest
already_imported:
)

manifest_to_import.types_depended_on do |type|
manifest_to_import.types_depended_on.each do |type|
run_subcommand!(
ImportType,
raw_manifest: manifest_data,
Expand All @@ -44,7 +44,9 @@ def build_error
base_error = if base_error_name
Foobara.foobara_root_namespace.foobara_lookup_error!(base_error_name)
else
# :nocov:
Foobara::Error
# :nocov:
end

Foobara::Error.subclass(
Expand Down

0 comments on commit 9926c3b

Please sign in to comment.