spec :: Spec
spec = do
  describe "notesTransform" $ do
    it "turns a span class='note' into a pandoc Note" $
      notesTransform noteScalar noteSpan `shouldBe` processedNoteSpan
  describe "pageToBlocks" $ do
    it "takes a 'Page' and returns Right '[Block]'" $
      pageToBlocks def singlePageScalarPage `shouldBeScalar` Right (singlePageTitle : singlePageContentPandoc)
  describe "scalarToPandoc" $ do
    it "takes a 'Scalar' book and returns 'Pandoc'" $ do
      scalarToPandoc def singlePageScalar { scalarOptions = def { orderPagesBy = None }} `shouldBeScalar` Right singlePagePandoc
  describe "readScalar" $ do
    it "parses a Scalar RDF/XML string into Right 'Pandoc'" $
      readScalar def def {orderPagesBy = None } (getExample "single_page.xml") `shouldBeScalar` Right singlePagePandoc
    it "parses a complex Scalar RDF/XML string into Right 'Pandoc'" $
      readScalar def def (getExample "full_book.xml") `shouldSatisfyScalar` isRight
spec :: Spec
spec = do
  describe "notesTransform" $ do
    it "turns a span class='note' into a pandoc Note" $
      notesTransform noteScalar noteSpan `shouldBe` processedNoteSpan
  describe "pageToBlocks" $ do
    it "takes a 'Page' and returns Right '[Block]'" $
      pageToBlocks def singlePageScalarPage `shouldBeScalar` Right (singlePageTitle : singlePageContentPandoc)
  describe "scalarToPandoc" $ do
    it "takes a 'Scalar' book and returns 'Pandoc'" $ do
      scalarToPandoc def singlePageScalar { scalarOptions = def { orderPagesBy = None }} `shouldBeScalar` Right singlePagePandoc
  describe "readScalar" $ do
    it "parses a Scalar RDF/XML string into Right 'Pandoc'" $
      readScalar def def {orderPagesBy = None } (getExample "single_page.xml") `shouldBeScalar` Right singlePagePandoc
    it "parses a complex Scalar RDF/XML string into Right 'Pandoc'" $
      readScalar def def (getExample "full_book.xml") `shouldSatisfyScalar` isRight
spec = do
  describe "notesTransform" $ do
    it "turns a span class='note' into a pandoc Note" $
      notesTransform noteScalar noteSpan `shouldBe` processedNoteSpan
  describe "pageToBlocks" $ do
    it "takes a 'Page' and returns Right '[Block]'" $
      pageToBlocks def singlePageScalarPage `shouldBeScalar` Right (singlePageTitle : singlePageContentPandoc)
  describe "scalarToPandoc" $ do
    it "takes a 'Scalar' book and returns 'Pandoc'" $ do
      scalarToPandoc def singlePageScalar { scalarOptions = def { orderPagesBy = None }} `shouldBeScalar` Right singlePagePandoc
  describe "readScalar" $ do
    it "parses a Scalar RDF/XML string into Right 'Pandoc'" $
      readScalar def def {orderPagesBy = None } (getExample "single_page.xml") `shouldBeScalar` Right singlePagePandoc
    it "parses a complex Scalar RDF/XML string into Right 'Pandoc'" $
      readScalar def def (getExample "full_book.xml") `shouldSatisfyScalar` isRight