spec/object_file_spec.rb in assembly-objectfile-1.6.4 vs spec/object_file_spec.rb in assembly-objectfile-1.6.5

- old
+ new

@@ -21,15 +21,16 @@ File.exists?(TEST_TIF_INPUT_FILE).should be true @ai = Assembly::ObjectFile.new(TEST_TIF_INPUT_FILE) @ai.image?.should == true @ai.exif.should_not be nil @ai.mimetype.should == 'image/tiff' + @ai.file_mimetype.should == 'image/tiff' @ai.object_type.should == :image @ai.valid_image?.should == true @ai.jp2able?.should == true end - + it "should tell us information about the input file" do @ai = Assembly::ObjectFile.new(TEST_TIF_INPUT_FILE) @ai.filename.should == "test.tif" @ai.ext.should == ".tif" @ai.filename_without_ext.should == "test" @@ -116,11 +117,11 @@ non_image_file=File.join(Assembly::PATH_TO_GEM,'README.rdoc') File.exists?(non_image_file).should be true @ai = Assembly::ObjectFile.new(non_image_file) @ai.image?.should == false - @ai.object_type.should == :text + @ai.object_type.should == :other @ai.valid_image?.should == false end it "should tell us the size of an input file" do File.exists?(TEST_TIF_INPUT_FILE).should be true @@ -130,9 +131,10 @@ it "should tell us the mimetype and encoding of an input file" do File.exists?(TEST_TIF_INPUT_FILE).should be true @ai = Assembly::ObjectFile.new(TEST_TIF_INPUT_FILE) @ai.mimetype.should == 'image/tiff' + @ai.file_mimetype.should == 'image/tiff' @ai.encoding.should == 'binary' end end \ No newline at end of file