input: Write a python function to extract text from each page of a PDF using PyPDF2.
  assert extract_text_from_pdf('sample.pdf')[0].startswith('First page text')
  assert len(extract_text_from_pdf('sample.pdf')) == 3
  assert isinstance(extract_text_from_pdf('sample.pdf'), list)
output: def extract_text_from_pdf(pdf_path):
      import PyPDF2
  
      text_pages = []
      with open(pdf_path, 'rb') as file:
          reader = PyPDF2.PdfFileReader(file)
          for page_num in range(reader.numPages):
              page = reader.getPage(page_num)
              text_pages.append(page.extract_text())
      
      return text_pages