JobSpy/tests/test_glassdoor.py

14 lines
319 B
Python
Raw Normal View History

2024-10-19 14:56:38 -07:00
from jobspy import scrape_jobs
2023-10-30 17:57:36 -07:00
import pandas as pd
2024-07-19 12:25:25 -07:00
def test_glassdoor():
2023-10-30 17:57:36 -07:00
result = scrape_jobs(
2024-07-19 12:25:25 -07:00
site_name="glassdoor",
search_term="engineer",
results_wanted=5,
2023-10-30 17:57:36 -07:00
)
assert (
2024-07-19 12:25:25 -07:00
isinstance(result, pd.DataFrame) and len(result) == 5
2023-10-30 17:57:36 -07:00
), "Result should be a non-empty DataFrame"