Sha256: 939bf6d58d2399b69ce404c5b6a19459df1a0bbc796e8499729685f88933686f
Contents?: true
Size: 903 Bytes
Versions: 22
Compression:
Stored size: 903 Bytes
Contents
describe "repetitive definitions" do context "of params" do subject do class Test::Foo extend Dry::Initializer::Mixin param :foo param :bar param :foo end end it "raise SyntaxError" do expect { subject }.to raise_error SyntaxError, /foo/ end end context "of options" do subject do class Test::Foo extend Dry::Initializer::Mixin option :foo option :bar option :foo end end it "raise SyntaxError" do expect { subject }.to raise_error SyntaxError, /foo/ end end context "of param and option" do subject do class Test::Foo extend Dry::Initializer::Mixin param :foo option :bar option :foo end end it "raise SyntaxError" do expect { subject }.to raise_error SyntaxError, /foo/ end end end
Version data entries
22 entries across 22 versions & 1 rubygems