Upgrade black
This commit is contained in:
parent
fad875b332
commit
dbdce83067
3 changed files with 1208 additions and 914 deletions
|
|
@ -1,6 +1,5 @@
|
|||
"""Factory to create `Courier` instances."""
|
||||
|
||||
|
||||
import factory
|
||||
from factory import alchemy
|
||||
|
||||
|
|
|
|||
|
|
@ -42,7 +42,8 @@ class AdHocOrderFactory(alchemy.SQLAlchemyModelFactory):
|
|||
# Timestamps after `cancelled_at` are discarded
|
||||
# by the `post_generation` hook at the end of the `OrderFactory`.
|
||||
cancel_ = factory.Trait( # noqa:WPS120 -> leading underscore does not work
|
||||
cancelled=True, cancelled_at_corrected=False,
|
||||
cancelled=True,
|
||||
cancelled_at_corrected=False,
|
||||
)
|
||||
cancel_before_pickup = factory.Trait(
|
||||
cancel_=True,
|
||||
|
|
|
|||
|
|
@ -137,7 +137,10 @@ def make_replay_order(make_order, simulation):
|
|||
order = make_order()
|
||||
|
||||
return factories.ReplayedOrderFactory.build(
|
||||
simulation=simulation, actual=order, courier=order.courier, **kwargs,
|
||||
simulation=simulation,
|
||||
actual=order,
|
||||
courier=order.courier,
|
||||
**kwargs,
|
||||
)
|
||||
|
||||
return func
|
||||
|
|
|
|||
Loading…
Reference in a new issue