first setup, travel works, bjornd api works
This commit is contained in:
17
tests/test_adapters.py
Normal file
17
tests/test_adapters.py
Normal file
@@ -0,0 +1,17 @@
|
||||
import sys
|
||||
sys.path.insert(0, "../src")
|
||||
|
||||
from cache import * # noqa: F401 — must be before adapter imports
|
||||
|
||||
from adapters import SCRAPERS
|
||||
|
||||
|
||||
# --- change this to test a different adapter ---
|
||||
ADAPTER = SCRAPERS['bjornd']
|
||||
|
||||
if __name__ == "__main__":
|
||||
print(f"Testing adapter: {ADAPTER.__name__}")
|
||||
listings = ADAPTER()
|
||||
print(f"Got {len(listings)} listings\n")
|
||||
for l in listings:
|
||||
print(f" {l.adres}, {l.stad} — €{l.prijs} — {l.url}")
|
||||
Reference in New Issue
Block a user