mirror of
https://code.eliotberriot.com/funkwhale/funkwhale.git
synced 2025-10-05 17:28:12 +02:00
See #170: can now subscribe/unsubscribe to channel
This commit is contained in:
parent
fc850e6e5d
commit
4236cc6274
5 changed files with 104 additions and 1 deletions
|
@ -33,3 +33,14 @@ class ChannelFactory(NoUpdateOnCreate, factory.django.DjangoModelFactory):
|
|||
),
|
||||
artist__local=True,
|
||||
)
|
||||
|
||||
|
||||
@registry.register(name="audio.Subscription")
|
||||
class SubscriptionFactory(NoUpdateOnCreate, factory.django.DjangoModelFactory):
|
||||
uuid = factory.Faker("uuid4")
|
||||
approved = True
|
||||
target = factory.LazyAttribute(lambda o: ChannelFactory().actor)
|
||||
actor = factory.SubFactory(federation_factories.ActorFactory)
|
||||
|
||||
class Meta:
|
||||
model = "federation.Follow"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue