Sha256: 3cc3f2888e1fc0f1b132aa99e50ecefcf0139aff2b83d8e2d8dc95f2e88ba96c
Contents?: true
Size: 771 Bytes
Versions: 2
Compression:
Stored size: 771 Bytes
Contents
require 'spec_helper' require 'server_helper' require 'kangaroo/util/loader' module Kangaroo module Util describe Loader do # include TestServerHelper def config_file File.join File.dirname(__FILE__), '..', 'test_env', 'test.yml' end it "replaces wildcards in model names" do loader = Loader.new ['res.*'], nil loader.model_names.should == ['res.%'] end it "uses global wildcard if model_names = :all" do loader = Loader.new :all, nil loader.model_names.should == ['%'] end it 'raises error if model_names = nil or empty' do lambda { Loader.new nil, nil }.should raise_error lambda { Loader.new [], nil }.should raise_error end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
kangaroo-0.0.3 | spec/util/loader_spec.rb |
kangaroo-0.0.2 | spec/util/loader_spec.rb |