Add test_reports file

This commit is contained in:
JNadeu 2018-10-11 18:19:33 +02:00
parent f4418fc72a
commit e92f64d88d
1 changed files with 16 additions and 0 deletions

16
tests/test_reports.py Normal file
View File

@ -0,0 +1,16 @@
from ereuse_devicehub.client import UserClient
from ereuse_devicehub.resources.device.models import Device
from ereuse_devicehub.resources.event.models import Snapshot
from tests.conftest import file
def test_export(user: UserClient):
snapshot, _ = user.post(file('basic.snapshot'), res=Snapshot)
device_id = snapshot['device']['id']
spreadsheet, _ = user.get(res=Device, accept='text/csv')
csv.reader()
assert
# import csv mirar com la lib python treballa