We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1b92daf commit c632d5cCopy full SHA for c632d5c
hyperproof/spec/unit/cfa_security_controls/hyperproof_spec.rb
@@ -10,7 +10,10 @@
10
end
11
12
let(:entity) do
13
- instance_double(CfaSecurityControls::Hyperproof::Entities::Proof, create: true)
+ instance_double(CfaSecurityControls::Hyperproof::Entities::Proof, create: true).tap do |entity|
14
+ # Allow the entity to return an ID, but only once create has been called.
15
+ allow(entity).to receive(:create) { allow(entity).to receive(:id).and_return(123) }
16
+ end
17
18
19
let(:label) do
0 commit comments