mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-12-19 14:48:59 +00:00
Removes start reading with progress test
There's no way to do this from the ui???? I don't tihnk there ever was???
This commit is contained in:
parent
a00fdc6864
commit
625ab46059
1 changed files with 3 additions and 11 deletions
|
@ -57,7 +57,6 @@ class ReadThrough(TestCase):
|
|||
"/start-reading/{}".format(self.edition.id),
|
||||
{
|
||||
"start_date": "2020-11-27",
|
||||
"progress": 50,
|
||||
},
|
||||
)
|
||||
|
||||
|
@ -66,15 +65,8 @@ class ReadThrough(TestCase):
|
|||
self.assertEqual(
|
||||
readthroughs[0].start_date, datetime(2020, 11, 27, tzinfo=timezone.utc)
|
||||
)
|
||||
self.assertEqual(readthroughs[0].progress, 50)
|
||||
self.assertEqual(readthroughs[0].finish_date, None)
|
||||
|
||||
progress_updates = readthroughs[0].progressupdate_set.all()
|
||||
self.assertEqual(len(progress_updates), 1)
|
||||
self.assertEqual(progress_updates[0].mode, models.ProgressMode.PAGE)
|
||||
self.assertEqual(progress_updates[0].progress, 50)
|
||||
self.assertEqual(delay_mock.call_count, 1)
|
||||
|
||||
# Update progress
|
||||
self.client.post(
|
||||
"/edit-readthrough",
|
||||
|
@ -87,9 +79,9 @@ class ReadThrough(TestCase):
|
|||
progress_updates = (
|
||||
readthroughs[0].progressupdate_set.order_by("updated_date").all()
|
||||
)
|
||||
self.assertEqual(len(progress_updates), 2)
|
||||
self.assertEqual(progress_updates[1].mode, models.ProgressMode.PAGE)
|
||||
self.assertEqual(progress_updates[1].progress, 100)
|
||||
self.assertEqual(len(progress_updates), 1)
|
||||
self.assertEqual(progress_updates[0].mode, models.ProgressMode.PAGE)
|
||||
self.assertEqual(progress_updates[0].progress, 100)
|
||||
|
||||
# Edit doesn't publish anything
|
||||
self.assertEqual(delay_mock.call_count, 1)
|
||||
|
|
Loading…
Reference in a new issue