Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
async def test_construct_using_async_with():
async with AioJikan() as temp_aio_jikan:
assert isinstance(temp_aio_jikan, AioJikan)
async def test_strip_base_url():
async with AioJikan("http://localhost:8000/v3/") as temp_aio_jikan:
assert temp_aio_jikan.base == "http://localhost:8000/v3"
async with AioJikan("http://localhost:8000/v3/ ") as temp_aio_jikan_2:
assert temp_aio_jikan_2.base == "http://localhost:8000/v3"
def aio_jikan():
return AioJikan()
async def test_strip_base_url():
async with AioJikan("http://localhost:8000/v3/") as temp_aio_jikan:
assert temp_aio_jikan.base == "http://localhost:8000/v3"
async with AioJikan("http://localhost:8000/v3/ ") as temp_aio_jikan_2:
assert temp_aio_jikan_2.base == "http://localhost:8000/v3"
from pprint import pprint
import asyncio
from jikanpy import AioJikan
aio_jikan = AioJikan()
async def main():
async with AioJikan() as aio_jikan:
mushishi = await aio_jikan.anime(457)
pprint(mushishi)
fma = await aio_jikan.manga(25)
pprint(fma)
ginko = await aio_jikan.character(425)
pprint(ginko)
naruto = await aio_jikan.search(search_type="anime", query="naruto")
pprint(naruto)