Sha256: f259e4e6215c4609672950338b5356dc79a82603ee4a3bcc733c730851697f26

Contents?: true

Size: 891 Bytes

Versions: 4

Compression:

Stored size: 891 Bytes

Contents

# frozen_string_literal: true

require 'spec_helper'
require 'uploadcare/rails/api/rest/project_api'

module Uploadcare
  module Rails
    module Api
      module Rest
        RSpec.describe ProjectApi do
          subject { Uploadcare::ProjectApi }

          context 'when checking methods' do
            it 'responds to expected REST methods' do
              expect(subject).to respond_to('get_project')
            end
          end

          context 'when sending requests', :aggregate_failures do
            it 'gets project info' do
              VCR.use_cassette('project_api_get_project') do
                response = subject.get_project
                %w[collaborators name pub_key autostore_enabled].each do |key|
                  expect(response).to have_key(key)
                end
              end
            end
          end
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
uploadcare-rails-3.2.0 spec/uploadcare/rails/api/rest/project_api_spec.rb
uploadcare-rails-2.1.1 spec/uploadcare/rails/api/rest/project_api_spec.rb
uploadcare-rails-2.1.0 spec/uploadcare/rails/api/rest/project_api_spec.rb
uploadcare-rails-2.0.0 spec/uploadcare/rails/api/rest/project_api_spec.rb