Sha256: 8c8c4da37803648c834e5f7f3b146b1c69e42e7a5b537c55a2f7414a75d0837c

Contents?: true

Size: 1.6 KB

Versions: 30

Compression:

Stored size: 1.6 KB

Contents

require 'rails_helper'

module MnoEnterprise
  RSpec.describe Jpi::V1::OrganizationsController, type: :routing do
    routes { MnoEnterprise::Engine.routes }
    
    it 'routes to #index' do
      expect(get('/jpi/v1/organizations')).to route_to("mno_enterprise/jpi/v1/organizations#index")
    end
    
    it 'routes to #show' do
      expect(get('/jpi/v1/organizations/1')).to route_to("mno_enterprise/jpi/v1/organizations#show", id: '1')
    end
    
    it 'routes to #create' do
      expect(post('/jpi/v1/organizations')).to route_to("mno_enterprise/jpi/v1/organizations#create")
    end
    
    it 'routes to #update' do
      expect(put('/jpi/v1/organizations/1')).to route_to("mno_enterprise/jpi/v1/organizations#update", id: '1')
    end

    it 'routes to #destroy' do
      expect(delete('/jpi/v1/organizations/1')).to route_to("mno_enterprise/jpi/v1/organizations#destroy", id: '1')
    end

    it "routes to #update_billing" do
      expect(put("/jpi/v1/organizations/1/update_billing")).to route_to("mno_enterprise/jpi/v1/organizations#update_billing",id: '1')
    end
    
    it "routes to #invite_members" do
      expect(put("/jpi/v1/organizations/1/invite_members")).to route_to("mno_enterprise/jpi/v1/organizations#invite_members",id: '1')
    end

    it "routes to #update_member" do
      expect(put("/jpi/v1/organizations/1/update_member")).to route_to("mno_enterprise/jpi/v1/organizations#update_member",id: '1')
    end

    it "routes to #remove_member" do
      expect(put("/jpi/v1/organizations/1/remove_member")).to route_to("mno_enterprise/jpi/v1/organizations#remove_member",id: '1')
    end
  end
end

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
mno-enterprise-api-3.4.0 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.3.3 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.3.2 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.2.1 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.3.1 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.3.0 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.2.0 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.1.4 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.0.7 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-2.0.9 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.1.3 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.0.6 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-2.0.8 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.1.2 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.0.5 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-2.0.7 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-2.0.6 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-2.0.5 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.1.1 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb
mno-enterprise-api-3.0.4 spec/routing/mno_enterprise/jpi/v1/organizations_controller_routing_spec.rb