spec/models/image_search_spec.rb

Summary

Maintainability
A
0 mins
Test Coverage

Prefer have_received for setting message expectations. Setup Elasticsearch::Persistence as a spy using allow or instance_spy.
Open

      expect(Elasticsearch::Persistence).to receive(:client).and_return(nil)
Severity: Minor
Found in spec/models/image_search_spec.rb by rubocop

Prefer allow over expect when configuring a response.
Open

      expect(Elasticsearch::Persistence).to receive(:client).and_return(nil)
Severity: Minor
Found in spec/models/image_search_spec.rb by rubocop

Do not use expect in before hook
Open

      expect(Elasticsearch::Persistence.client).to receive(:search).and_return(result)
Severity: Minor
Found in spec/models/image_search_spec.rb by rubocop

Prefer allow over expect when configuring a response.
Open

      expect(Elasticsearch::Persistence.client).to receive(:search).and_return(result)
Severity: Minor
Found in spec/models/image_search_spec.rb by rubocop

Prefer have_received for setting message expectations. Setup Elasticsearch::Persistence.client as a spy using allow or instance_spy.
Open

      expect(Elasticsearch::Persistence.client).to receive(:search).and_return(result)
Severity: Minor
Found in spec/models/image_search_spec.rb by rubocop

There are no issues that match your filters.

Category
Status