code: def test_read_less_simple_file(
      pynb="""# ---
  # title: Less simple file
  # ---
  
  # Here we have some text
  # And below we have some python code
  
  # This is a comment about function f
  def f(x):
      return x+1
  
  
  # And a comment on h
  def h(y):
      return y-1
  """,
  ):
      nb = jupytext.reads(pynb, "py")
  
      assert len(nb.cells) == 4
      assert nb.cells[0].cell_type == "raw"
      assert nb.cells[0].source == "---\ntitle: Less simple file\n---"
      assert nb.cells[1].cell_type == "markdown"
      assert (
          nb.cells[1].source == "Here we have some text\n"
          "And below we have some python code"
      )
      assert nb.cells[2].cell_type == "code"
      compare(
          nb.cells[2].source,
          "# This is a comment about function f\n"
          "def f(x):\n"
          "    return x+1",
      )
      assert nb.cells[3].cell_type == "code"
      compare(
          nb.cells[3].source,
          """# And a comment on h\ndef h(y):\n    return y-1""",
      )
  
      pynb2 = jupytext.writes(nb, "py")
      compare(pynb2, pynb)
  
imports: import pytest
  from nbformat.v4.nbbase import new_code_cell, new_markdown_cell, new_notebook, new_raw_cell
  import jupytext
  from jupytext.compare import compare, compare_notebooks
label_desc: Use image node_id 2 for calling a global function with example usage: test_read_less_simple_file(pynb) without return types