Sha256: 641e3c91ea6f56f4f25974a681301e2dca05552f9583b813d0c6d68be8a2d84a
Contents?: true
Size: 831 Bytes
Versions: 15
Compression:
Stored size: 831 Bytes
Contents
require 'rails_helper' describe LHS::Endpoint do context 'for url' do before(:each) do class SomeService < LHS::Service endpoint ':datastore/entries/:entry_id/content-ads/:campaign_id/feedbacks' endpoint ':datastore/:campaign_id/feedbacks' endpoint ':datastore/feedbacks' end end it 'provides the endpoint for a given url' do expect( LHS::Endpoint.for_url('http://local.ch/v2/entries/123/content-ads/456/feedbacks').url ).to eq ':datastore/entries/:entry_id/content-ads/:campaign_id/feedbacks' expect( LHS::Endpoint.for_url('http://local.ch/123/feedbacks').url ).to eq ':datastore/:campaign_id/feedbacks' expect( LHS::Endpoint.for_url('http://local.ch/feedbacks').url ).to eq ':datastore/feedbacks' end end end
Version data entries
15 entries across 15 versions & 1 rubygems