Created
July 20, 2019 19:18
-
-
Save zmariscal/936c97811017f90b3f45201af88d11fb to your computer and use it in GitHub Desktop.
Optional org_admin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## user within a shared context | |
let(:options) { opts || {} } | |
let(:access) { options[:access] || {} } | |
let(:role) { options.fetch(:role, "standard") } | |
let(:org_admin) { options.fetch(:org_admin, false) } | |
let!(:membership) { current_user.account_memberships.create!(account: account, role: role, organization_administrator: access[:org_admin]) } | |
## shared context in spec | |
context "as an admin insight core user" do | |
include_context "insight core user", role: :power, org_admin: :true | |
include_examples "can invite new account members" | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment