Sha256: 5cef50e3dafd68e9310804076e185ff781643c48f9082f1c5caffcc2d11dcb84
Contents?: true
Size: 751 Bytes
Versions: 1
Compression:
Stored size: 751 Bytes
Contents
require 'spec_helper' describe Conjur::Command::Resources, logged_in: true do describe_command "resource:check food bacon fry" do it "performs a permission check for the logged-in user" do api.should_receive(:resource).with("the-account:food:bacon").and_return bacon = double("the-account:food:bacon") bacon.should_receive(:permitted?).with("fry") invoke end end describe_command "resource:check -r test:the-role food bacon fry" do it "performs a permission check for a specified role" do api.should_receive(:role).with("test:the-role").and_return role = double("the-account:test:the-role") role.should_receive(:permitted?).with("food", "bacon", "fry") invoke end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
conjur-cli-2.6.0 | spec/command/resources_spec.rb |