code: def do_notebook(self, name):
          
          CONVERT_NOTEBOOKS = int(os.getenv('CONVERT_NOTEBOOKS', True))
          s = StringIO()
          if mock:
              out = unittest.mock.patch('sys.stdout', new=MockDevice(s))
              err = unittest.mock.patch('sys.stderr', new=MockDevice(s))
              self._do_notebook(name, CONVERT_NOTEBOOKS)
              out.close()
              err.close()
          else:
              self._do_notebook(name, CONVERT_NOTEBOOKS)
          self.assertTrue(True)
docs: Run a notebook file after optionally
          converting it to a python file.