code: def test_wb_read_only():
      """
      Raise error if Workbook is provided, and read_only is True.
      """
      wb = load_workbook(filename, read_only=True)
      with pytest.raises(
          AttributeError,
          match="Accessing the tables.+",
      ):
          io.xlsx_table(wb, "Tables")
      wb.close()
  
file_path: pyjanitor/tests/io/test_xlsx_table.py
imports: from pathlib import Path
  import pandas
  import pytest
  from openpyxl import load_workbook
  from pandas.testing import assert_frame_equal
  from janitor import io
label_desc: Use image node_id 5 for calling a global function with example usage: test_wb_read_only() without return types