Skip to content

Commit

Permalink
clean up bad_008 specs (#73)
Browse files Browse the repository at this point in the history
  • Loading branch information
mzelesky authored Nov 27, 2023
1 parent a7a9979 commit f067316
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
require 'byebug'
require 'marc_cleanup'

RSpec.describe 'test bad_008?' do
RSpec.describe 'bad_008?' do
describe 'bad book format 008' do
let(:marcfile) {"#{Dir.getwd}/spec/fixtures/fixed_fields/marc_with_bad_book_008.xml"}
let(:reader) { MARC::XMLReader.new(marcfile, parser: 'magic') }
Expand All @@ -12,4 +12,12 @@
expect(MarcCleanup.bad_008?(record_with_bad_008)).to eq true
end
end
end
describe 'bad computer format 008' do
let(:marcfile) {"#{Dir.getwd}/spec/fixtures/fixed_fields/marc_with_bad_comp_008.xml"}
let(:reader) { MARC::XMLReader.new(marcfile, parser: 'magic') }
let(:record_with_bad_008) { reader.first }
it 'knows that a record with bad computer 008 is invalid' do
expect(MarcCleanup.bad_008?(record_with_bad_008)).to eq true
end
end
end
15 changes: 0 additions & 15 deletions spec/fixed_fields/comp_format_bad_008_spec.rb

This file was deleted.

0 comments on commit f067316

Please sign in to comment.