fixing tests
This commit is contained in:
parent
e2898b22a3
commit
882ee381b3
|
@ -119,4 +119,4 @@ def test_api_docs(client: Client):
|
||||||
'scheme': 'basic',
|
'scheme': 'basic',
|
||||||
'name': 'Authorization'
|
'name': 'Authorization'
|
||||||
}
|
}
|
||||||
assert len(docs['definitions']) == 119
|
assert len(docs['definitions']) == 120
|
||||||
|
|
|
@ -413,10 +413,8 @@ def test_lot_error_add_device_from_other_user(user: UserClient):
|
||||||
res=Lot,
|
res=Lot,
|
||||||
item='{}/devices'.format(parent['id']),
|
item='{}/devices'.format(parent['id']),
|
||||||
query=[('id', device_id)])
|
query=[('id', device_id)])
|
||||||
assert lot['devices'][0]['id'] == device_id, 'Lot contains device'
|
assert lot['devices'] == [], 'Lot contains device'
|
||||||
assert len(lot['devices']) == 1
|
assert len(lot['devices']) == 0
|
||||||
with raises(JSONDecodeError):
|
|
||||||
device, _ = user.get(res=Device, item=device.devicehub_id)
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.mvp
|
@pytest.mark.mvp
|
||||||
|
|
|
@ -29,7 +29,7 @@ from ereuse_devicehub.resources.device.sync import MismatchBetweenProperties, \
|
||||||
from ereuse_devicehub.resources.enums import ComputerChassis, SnapshotSoftware
|
from ereuse_devicehub.resources.enums import ComputerChassis, SnapshotSoftware
|
||||||
from ereuse_devicehub.resources.tag import Tag
|
from ereuse_devicehub.resources.tag import Tag
|
||||||
from ereuse_devicehub.resources.user.models import User
|
from ereuse_devicehub.resources.user.models import User
|
||||||
from ereuse_devicehub.resources.action.views import save_json
|
from ereuse_devicehub.resources.action.views.snapshot import save_json
|
||||||
from ereuse_devicehub.resources.documents import documents
|
from ereuse_devicehub.resources.documents import documents
|
||||||
from tests.conftest import file
|
from tests.conftest import file
|
||||||
from tests import conftest
|
from tests import conftest
|
||||||
|
|
Reference in New Issue