File tree Expand file tree Collapse file tree 2 files changed +8
-1
lines changed
spec/integration/messages Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ class Config
4646 setting :backend , default : :yaml
4747 setting :namespace
4848 setting :load_paths , default : ::Set [ DEFAULT_MESSAGES_PATH ] , constructor : :dup . to_proc
49- setting :top_namespace , default : DEFAULT_MESSAGES_ROOT
49+ setting :top_namespace , default : DEFAULT_MESSAGES_ROOT , constructor : :to_s . to_proc
5050 setting :default_locale
5151 end
5252
Original file line number Diff line number Diff line change 8989
9090 expect ( result . errors ( full : true ) [ :post_body ] ) . to eql ( [ "(dry_validation) Post body must be filled" ] )
9191 end
92+
93+ it "allows symbol for top namespace" do
94+ schema = Dry ::Schema . Params do
95+ config . messages . top_namespace = :dry_validation
96+ end
97+ assert_equal "dry_validation" , schema . config . messages . top_namespace
98+ end
9299 end
93100end
You can’t perform that action at this time.
0 commit comments