15 lines
334 B
Python
15 lines
334 B
Python
from pydantic_factories import ModelFactory
|
|
|
|
from pynyaata2.cache import client
|
|
from pynyaata2.types import RemoteFile
|
|
|
|
|
|
class RemoteFileFactory(ModelFactory[RemoteFile]):
|
|
__model__ = RemoteFile
|
|
|
|
|
|
def test_cache_data():
|
|
remote = RemoteFileFactory.build()
|
|
client.set("test", remote)
|
|
assert client.get("test") == remote
|