def setUp(self): super(FinishAuctionTests, self).setUp() self.auction = AuctionFactory.create(status=AUCTION_STATUS_OPEN) self.user1 = UserFactory.create() self.customer1 = CustomerFactory.create(user=self.user1) self.user2 = UserFactory.create() self.customer2 = CustomerFactory.create(user=self.user2) self.bid1 = BidFactory.create(auction=self.auction, user=self.user1, price=12000) self.bid2 = BidFactory.create(auction=self.auction, user=self.user2, price=13000)
def setUp(self): super(CommentListViewTests, self).setUp() self.post = PostFactory.create() self.user = UserFactory.create() self.comments = [ CommentFactory.create(post=self.post), CommentFactory.create(post=self.post), ]
def setUp(self): super(PostCommentSerializerTests, self).setUp() self.user = UserFactory.create() self.post = PostFactory.create() self.comments = [ CommentFactory.create(post=self.post), CommentFactory.create(post=self.post), ]
def setUp(self): super(UserBlockUnblockViewTests, self).setUp() self.user = UserFactory.create()
def setUp(self): self.client = APIClient() self.user = UserFactory.create() self.client.force_authenticate(user=self.user)
def setUp(self): super(BidSerializerTests, self).setUp() self.user = UserFactory.create() self.auction = AuctionFactory.create() open_until = timezone.now() + timedelta(days=3) self.auction.start(open_until)
def setUp(self): super(StartAuctionTests, self).setUp() self.auction = AuctionFactory.create() self.user = UserFactory.create()