How to load test data from test/fixtures yml file in Rails units
How to load test 开发者_运维知识库data from test/fixtures yml file in Rails units
fixtures/xxxs.yml
- one:
clm1: test
clm2: test
test/unit/xxx.rb
test "load_yml_obj" do
assert_not_nil xxxs(:one)
end
精彩评论