mirror of
https://code.eliotberriot.com/funkwhale/funkwhale.git
synced 2025-10-04 21:19:15 +02:00
See #170: cover on tracks and artists
This commit is contained in:
parent
db1cb30df8
commit
71b400a9b8
34 changed files with 582 additions and 254 deletions
|
@ -63,12 +63,13 @@ def test_db_serialize_update_mutation(factories, mutations_registry, mocker):
|
|||
user = factories["users.User"](email="hello@test.email", with_actor=True)
|
||||
|
||||
class S(mutations.UpdateMutationSerializer):
|
||||
serialized_relations = {"actor": "full_username"}
|
||||
|
||||
class Meta:
|
||||
model = user.__class__
|
||||
fields = ["actor"]
|
||||
|
||||
def get_serialized_relations(self):
|
||||
return {"actor": "full_username"}
|
||||
|
||||
expected = {"actor": user.actor.full_username}
|
||||
assert S().db_serialize({"actor": user.actor}) == expected
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue