Change CLI#recipe as read-only attribute
This commit is contained in:
parent
a7dde5afce
commit
b67a32d27e
@ -19,8 +19,7 @@ module Producer
|
||||
end
|
||||
end
|
||||
|
||||
attr_reader :arguments, :stdout
|
||||
attr_accessor :recipe
|
||||
attr_reader :arguments, :stdout, :recipe
|
||||
|
||||
def initialize(arguments, stdout: $stdout)
|
||||
raise ArgumentError unless arguments.any?
|
||||
|
@ -72,7 +72,7 @@ module Producer::Core
|
||||
describe '#recipe' do
|
||||
it 'returns the assigned recipe' do
|
||||
recipe = double 'recipe'
|
||||
cli.recipe = recipe
|
||||
cli.instance_eval { @recipe = recipe }
|
||||
expect(cli.recipe).to be recipe
|
||||
end
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user