|
3 | 3 | require 'nokogiri'
|
4 | 4 |
|
5 | 5 | describe GEPUB::Item do
|
6 |
| - it "should return atttributes" do |
| 6 | + it "should return attributes" do |
7 | 7 | item = GEPUB::Item.new('theid', 'foo/bar.bar', 'application/xhtml+xml')
|
8 | 8 | expect(item.itemid).to eq('theid')
|
9 | 9 | expect(item.href).to eq('foo/bar.bar')
|
|
52 | 52 | @book.spine.push(item1)
|
53 | 53 |
|
54 | 54 | item2 = @book.add_ordered_item('text/barbar.xhtml',
|
55 |
| - content: StringIO.new('<html xmlns="http://www.w3.org/1999/xhtml"><head><title>c2</title></head><body><p>second page, whith is test chapter.</p></body></html>'), |
| 55 | + content: StringIO.new('<html xmlns="http://www.w3.org/1999/xhtml"><head><title>c2</title></head><body><p>second page, with is test chapter.</p></body></html>'), |
56 | 56 | id: 'c2',
|
57 | 57 | toc_text: 'test chapter')
|
58 | 58 |
|
|
178 | 178 | item1.add_content(StringIO.new('<html xmlns="http://www.w3.org/1999/xhtml"><head><title>c1</title></head><body><p>the first page</p></body></html>'))
|
179 | 179 | @book.spine.push(item1)
|
180 | 180 | item2 = @book.add_ordered_item('text/barbar.xhtml',
|
181 |
| - content: StringIO.new('<html xmlns="http://www.w3.org/1999/xhtml"><head><title>c2</title></head><body><p>second page, whith is test chapter.</p></body></html>'), |
| 181 | + content: StringIO.new('<html xmlns="http://www.w3.org/1999/xhtml"><head><title>c2</title></head><body><p>second page, with is test chapter.</p></body></html>'), |
182 | 182 | id: 'c2')
|
183 | 183 | item2.toc_text 'test chapter'
|
184 | 184 | @book.generate_epub(epub_file)
|
|
206 | 206 | item1.add_content(StringIO.new('<html xmlns="http://www.w3.org/1999/xhtml"><head><title>c1</title></head><body><p>the first page</p></body></html>'))
|
207 | 207 | @book.spine.push(item1)
|
208 | 208 | item2 = @book.add_ordered_item('text/barbar.xhtml',
|
209 |
| - content: StringIO.new('<html xmlns="http://www.w3.org/1999/xhtml"><head><title>c2</title></head><body><p>second page, whith is test chapter.</p></body></html>'), |
| 209 | + content: StringIO.new('<html xmlns="http://www.w3.org/1999/xhtml"><head><title>c2</title></head><body><p>second page, with is test chapter.</p></body></html>'), |
210 | 210 | id: 'c2')
|
211 | 211 | @book.generate_epub(epub_file)
|
212 | 212 | epubcheck(epub_file)
|
|
0 commit comments