spec/requests/api/v1/collections_spec.rb

Summary

Maintainability
B
5 hrs
Test Coverage

File collections_spec.rb has 382 lines of code (exceeds 250 allowed). Consider refactoring.
Open

require 'rails_helper'

describe Api::V1::Collections do
  let(:valid_session) do
    env_secrets = Rails.application.config_for(:secrets)
Severity: Minor
Found in spec/requests/api/v1/collections_spec.rb - About 5 hrs to fix

    Prefer response.parsed_body to JSON.parse(response.body).
    Open

            expect(JSON.parse(response.body)).to match(

    Prefer response.parsed_body to JSON.parse(response.body).
    Open

            expect(JSON.parse(response.body)).to match(

    Prefer response.parsed_body to JSON.parse(response.body).
    Open

            expect(JSON.parse(response.body)).to match(

    Prefer response.parsed_body to JSON.parse(response.body).
    Open

            expect(JSON.parse(response.body)).to match(

    Prefer response.parsed_body to JSON.parse(response.body).
    Open

            let(:body) { JSON.parse(response.body) }

    Prefer response.parsed_body to JSON.parse(response.body).
    Open

            let(:body) { JSON.parse(response.body) }

    Prefer response.parsed_body to JSON.parse(response.body).
    Open

            expect(JSON.parse(response.body)).to match(

    Prefer response.parsed_body to JSON.parse(response.body).
    Open

            expect(JSON.parse(response.body)).to match(

    Prefer response.parsed_body to JSON.parse(response.body).
    Open

            expect(JSON.parse(response.body)).to match(

    Prefer response.parsed_body to JSON.parse(response.body).
    Open

            expect(JSON.parse(response.body)).to match(

    Prefer response.parsed_body to JSON.parse(response.body).
    Open

            expect(JSON.parse(response.body)).to match(

    There are no issues that match your filters.

    Category
    Status