spec/configuration/tab/files_spec.rb in lolita-file-upload-0.1.3 vs spec/configuration/tab/files_spec.rb in lolita-file-upload-0.1.4

- old
+ new

@@ -1,14 +1,14 @@ require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') -describe Lolita::Configuration::FilesTab do +describe Lolita::Configuration::Tab::Files do let(:dbi){Lolita::DBI::Base.new(Post)} - let(:tab){Lolita::Configuration::FilesTab.new(dbi)} + let(:tab){Lolita::Configuration::Tab::Files.new(dbi)} it "should create new file tab" do - Lolita::Configuration::FilesTab.new(dbi).type.should == :files + Lolita::Configuration::Tab::Files.new(dbi).type.should == :files end describe "extensions" do it "should return empty array for new tab" do @@ -19,11 +19,11 @@ tab.extensions=["pdf","xls"] tab.extensions.should == ["pdf", "xls"] end it "should allow to add new one" do - tab.extension("pdf") - tab.extensions.should == ["pdf"] + tab.extension("Image","pdf") + tab.extensions.should == [{:title=>"Image",:extensions=>"pdf"}] end end describe "maximum file size" do it "should be changable" do \ No newline at end of file