Sha256: d6e05fe9023d7f743fcd8c08ba6a6a1ce4593d2d6e9e0f045aa493a6b4b64f2d
Contents?: true
Size: 357 Bytes
Versions: 7
Compression:
Stored size: 357 Bytes
Contents
require 'spec_helper' describe 'A named API' do subject(:api_name) { NamedAPI.endpoints.last.options[:for].to_s } let(:api) do Class.new(Grape::API) do get 'test' do 'response' end end end before { stub_const('NamedAPI', api) } it 'can access the name of the API' do expect(api_name).to eq 'NamedAPI' end end
Version data entries
7 entries across 7 versions & 2 rubygems