Update cancan permissions for second iteration of bulk invoices

This commit is contained in:
Matt-Yorkley
2019-02-01 21:44:30 +00:00
parent a910468fc7
commit 2c3eeec2b9
3 changed files with 6 additions and 3 deletions

View File

@@ -2,10 +2,11 @@ require 'spec_helper'
describe Spree::Admin::InvoicesController, type: :controller do
let(:order) { create(:order_with_totals_and_distribution) }
let(:user) { create(:admin_user) }
let(:enterprise_user) { create(:user) }
let!(:enterprise) { create(:enterprise, owner: enterprise_user) }
before do
allow(controller).to receive(:spree_current_user) { user }
allow(controller).to receive(:spree_current_user) { enterprise_user }
end
describe "#create" do