spec/psd_spec.rb in psd-2.1.0 vs spec/psd_spec.rb in psd-2.1.1
- old
+ new
@@ -2,13 +2,19 @@
describe 'PSD' do
let(:filename) { 'spec/files/example.psd' }
it 'should open a file without a block' do
- psd = PSD.open(filename)
- expect(psd).to be_parsed
+ psd = PSD.new(filename)
+ expect(psd).to_not be_parsed
expect(psd).to be_an_instance_of(PSD)
end
+
+ it 'should raise an exception if using open without a block' do
+ expect {
+ PSD.open(filename)
+ }.to raise_error
+ end
it 'should refuse to open a bad filename' do
expect { PSD.open('') }.to raise_error
end
\ No newline at end of file