code: def test_jupyter_book_options_to_rmarkdown(md, rmd):
      """By default, Jupyter Book tags are mapped to R Markdown options, and vice versa #337"""
      md = (
          "```python "
          + md
          + """
  1 + 1
  ```
  """
      )
  
      rmd = (
          "```{python "
          + rmd
          + """}
  1 + 1
  ```
  """
      )
  
      nb_md = jupytext.reads(md, "md")
      nb_rmd = jupytext.reads(rmd, "Rmd")
      compare_notebooks(nb_rmd, nb_md)
  
      md2 = jupytext.writes(nb_rmd, "md")
      compare(md2, md)
  
      rmd = rmd.replace('"hide"', "'hide'")
      rmd2 = jupytext.writes(nb_md, "Rmd")
      compare(rmd2, rmd)
  
imports: import pytest
  import jupytext
  from jupytext.compare import compare, compare_notebooks
label_desc: Use image node_id 1 for calling a global function with example usage: test_jupyter_book_options_to_rmarkdown(md, rmd) without return types