Sha256: 42d977e02b2539bce2614fbcbb3d9fcd85667f1d9ef864917b464e92e0e7795a
Contents?: true
Size: 553 Bytes
Versions: 6
Compression:
Stored size: 553 Bytes
Contents
# encoding: utf-8 require 'spec_helper' describe Imap::Backup::Serializer::Base do context '#initialize' do let(:stat) { stub('File::Stat', :mode => 0345) } it 'should fail if file permissions are to lax' do File.stub!(:exist?).with('/base/path').and_return(true) File.should_receive(:stat).with('/base/path').and_return(stat) expect do Imap::Backup::Serializer::Base.new('/base/path', 'my_folder') end.to raise_error(RuntimeError, "Permissions on '/base/path' should be 0700, not 0345") end end end
Version data entries
6 entries across 6 versions & 1 rubygems