Sha256: 76666c4fbe070da21ec63f3c5f17354433e64930af6d080e6e3ef778c88f25aa
Contents?: true
Size: 422 Bytes
Versions: 45
Compression:
Stored size: 422 Bytes
Contents
require_relative "spec_helper" describe "Sequel::Plugins::ErrorSplitter" do before do @c = Class.new(Sequel::Model) @c.plugin :error_splitter @m = @c.new def @m.validate errors.add([:a, :b], 'is bad') end end it "should split errors for multiple columns and assign them to each column" do @m.valid?.must_equal false @m.errors.must_equal(:a=>['is bad'], :b=>['is bad']) end end
Version data entries
45 entries across 41 versions & 2 rubygems