mirror of
https://code.eliotberriot.com/funkwhale/funkwhale.git
synced 2025-10-05 05:59:28 +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
|
@ -179,9 +179,10 @@ def test_perm_checkers_can_approve(
|
|||
assert mutations.can_approve(obj, actor=actor) is expected
|
||||
|
||||
|
||||
def test_mutation_set_attachment_cover(factories, now, mocker):
|
||||
@pytest.mark.parametrize("factory_name", ["music.Artist", "music.Track", "music.Album"])
|
||||
def test_mutation_set_attachment_cover(factory_name, factories, now, mocker):
|
||||
new_attachment = factories["common.Attachment"](actor__local=True)
|
||||
obj = factories["music.Album"]()
|
||||
obj = factories[factory_name]()
|
||||
old_attachment = obj.attachment_cover
|
||||
mutation = factories["common.Mutation"](
|
||||
type="update", target=obj, payload={"cover": new_attachment.uuid}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue