Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
= committed Oct 7, 2024
1 parent 6ebbe91 commit 4c9e6ac
Showing 1 changed file with 0 additions and 28 deletions.
28 changes: 0 additions & 28 deletions auctions/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,6 @@ def setUp(self):
auction=self.online_auction,
auctiontos_seller=self.online_tos,
quantity=1,
description="",
winning_price=10,
auctiontos_winner=self.tosB,
active=False,
Expand All @@ -120,7 +119,6 @@ def setUp(self):
auction=self.online_auction,
auctiontos_seller=self.online_tos,
quantity=1,
description="",
winning_price=10,
auctiontos_winner=self.tosB,
active=False,
Expand All @@ -130,15 +128,13 @@ def setUp(self):
auction=self.online_auction,
auctiontos_seller=self.online_tos,
quantity=1,
description="",
winning_price=10,
auctiontos_winner=self.tosB,
active=False,
)
self.unsoldLot = Lot.objects.create(
lot_name="Unsold lot",
reserve_price=10,
description="",
auction=self.online_auction,
quantity=1,
auctiontos_seller=self.online_tos,
Expand Down Expand Up @@ -169,7 +165,6 @@ def setUp(self):
auction=self.in_person_auction,
auctiontos_seller=self.admin_in_person_tos,
quantity=1,
description="",
custom_lot_number="101-1",
)
# TODO: stuff to add here:
Expand Down Expand Up @@ -197,7 +192,6 @@ def setUp(self):
auction=self.auction,
user=self.user,
quantity=1,
description="",
)
self.url = reverse("lot_by_pk", kwargs={"pk": self.lot.pk})
# Create a user for the logged-in scenario
Expand Down Expand Up @@ -242,7 +236,6 @@ def test_lots_in_auction_end_with_auction(self):
auction=auction,
user=user,
quantity=1,
description="",
)
assert lot.ended is True

Expand All @@ -268,7 +261,6 @@ def test_calculated_end_bidding_closed(self):
reserve_price=5,
user=user,
quantity=1,
description="",
)
assert testLot.ended is False

Expand All @@ -284,7 +276,6 @@ def test_calculated_end_bidding_open(self):
reserve_price=5,
user=user,
quantity=1,
description="",
)
assert testLot.ended is True

Expand All @@ -296,7 +287,6 @@ def test_lot_with_no_bids(self):
date_end=time,
reserve_price=5,
user=user,
description="",
)
assert lot.high_bid == 5

Expand All @@ -307,7 +297,6 @@ def test_lot_with_one_bids(self):
lot_name="A test lot",
date_end=time,
reserve_price=5,
description="",
user=lotuser,
quantity=1,
)
Expand All @@ -323,7 +312,6 @@ def test_lot_with_two_bids(self):
lot_name="A test lot",
date_end=time,
reserve_price=5,
description="",
user=lotuser,
quantity=1,
)
Expand All @@ -341,7 +329,6 @@ def test_lot_with_two_changing_bids(self):
lot_name="A test lot",
date_end=time,
reserve_price=20,
description="",
user=lotuser,
quantity=6,
)
Expand Down Expand Up @@ -381,7 +368,6 @@ def test_lot_with_tie_bids(self):
lot_name="A test lot",
date_end=time,
reserve_price=5,
description="",
user=lotuser,
quantity=1,
)
Expand All @@ -407,7 +393,6 @@ def test_lot_with_three_and_two_tie_bids(self):
lot_name="A test lot",
date_end=time,
reserve_price=5,
description="",
user=lotuser,
quantity=1,
)
Expand Down Expand Up @@ -435,7 +420,6 @@ def test_lot_with_two_bids_one_after_end(self):
lot_name="A test lot",
date_end=time,
reserve_price=5,
description="",
user=lotuser,
quantity=1,
)
Expand All @@ -455,7 +439,6 @@ def test_lot_with_one_bids_below_reserve(self):
lot_name="A test lot",
date_end=time,
reserve_price=5,
description="",
user=lotuser,
quantity=1,
)
Expand All @@ -473,31 +456,27 @@ def test_chat_subscriptions(self):
lot_name="A test lot",
date_end=timezone.now() + datetime.timedelta(days=30),
reserve_price=5,
description="",
user=lotuser,
quantity=1,
)
my_lot_that_i_have_seen_all = Lot.objects.create(
lot_name="seen all",
date_end=timezone.now() + datetime.timedelta(days=30),
reserve_price=5,
description="",
user=lotuser,
quantity=1,
)
someone_elses_lot = Lot.objects.create(
lot_name="Another test lot",
date_end=timezone.now() + datetime.timedelta(days=30),
reserve_price=5,
description="",
user=chatuser,
quantity=1,
)
my_lot_that_is_unsubscribed = Lot.objects.create(
lot_name="An unsubscribed lot",
date_end=timezone.now() + datetime.timedelta(days=30),
reserve_price=5,
description="",
user=lotuser,
quantity=1,
)
Expand Down Expand Up @@ -681,15 +660,13 @@ def setUp(self):
auction=self.auction,
auctiontos_seller=self.tos,
quantity=1,
description="",
winning_price=10,
auctiontos_winner=self.tosB,
active=False,
)
self.unsold_lot = Lot.objects.create(
lot_name="Unsold lot",
reserve_price=10,
description="",
auction=self.auction,
quantity=1,
auctiontos_seller=self.tos,
Expand All @@ -698,7 +675,6 @@ def setUp(self):
self.sold_no_auction_lot = Lot.objects.create(
lot_name="not in the auction",
reserve_price=10,
description="",
auction=None,
quantity=1,
user=self.user,
Expand All @@ -709,7 +685,6 @@ def setUp(self):
self.unsold_no_auction_lot = Lot.objects.create(
lot_name="unsold not in the auction",
reserve_price=10,
description="",
auction=None,
quantity=1,
user=self.user,
Expand Down Expand Up @@ -842,15 +817,13 @@ def setUp(self):
auction=self.auction,
auctiontos_seller=self.seller,
quantity=1,
description="",
)
self.lot2 = Lot.objects.create(
custom_lot_number="124",
lot_name="Another test lot",
auction=self.auction,
auctiontos_seller=self.seller,
quantity=1,
description="",
)
self.client = Client()
self.client.login(username="testuser", password="testpassword")
Expand All @@ -860,7 +833,6 @@ def setUp(self):
reserve_price=10,
user=self.user,
active=True,
description="",
)
self.lot_url = reverse("lot_refund", kwargs={"pk": self.lot.pk})

Expand Down

0 comments on commit 4c9e6ac

Please sign in to comment.