committing survey
This commit is contained in:
@@ -20,7 +20,7 @@ class VirtualEventViewTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
self.c = Client()
|
||||
@@ -36,7 +36,7 @@ class VirtualEventViewTest(TestCase):
|
||||
|
||||
self.rpiet = Rower.objects.create(user=self.upiet,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='basic')
|
||||
|
||||
self.piet_workouts = WorkoutFactory.create_batch(5, user=self.rpiet)
|
||||
@@ -49,7 +49,7 @@ class VirtualEventViewTest(TestCase):
|
||||
|
||||
self.rklaas = Rower.objects.create(user=self.uklaas,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='basic')
|
||||
|
||||
self.klaas_workouts = WorkoutFactory.create_batch(5, user=self.rklaas)
|
||||
@@ -62,7 +62,7 @@ class VirtualEventViewTest(TestCase):
|
||||
|
||||
self.rhenk = Rower.objects.create(user=self.uhenk,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='basic')
|
||||
|
||||
self.henk_workouts = WorkoutFactory.create_batch(5, user=self.rhenk)
|
||||
@@ -851,4 +851,3 @@ class VirtualEventViewTest(TestCase):
|
||||
# standalone
|
||||
# calculate course adherence
|
||||
# other background jobs
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ class WorkoutCompareTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -81,7 +81,7 @@ class BoxPlotTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -179,7 +179,7 @@ class ListWorkoutTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -230,7 +230,7 @@ class PlannedSessionTests(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -281,7 +281,7 @@ class ForcecurveTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -317,7 +317,7 @@ class CumStatsTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -354,7 +354,7 @@ class CumFlexTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -459,7 +459,7 @@ class MultiFlexTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -561,7 +561,7 @@ class HistoTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -650,7 +650,7 @@ class WorkoutCompareTestNew(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -739,7 +739,7 @@ class WorkoutBoxPlotTestNew(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -827,7 +827,7 @@ class WorkoutHistoTestNew(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -915,7 +915,7 @@ class WorkoutFlexallTestNew(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -1003,7 +1003,7 @@ class WorkoutStatsTestNew(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -1134,4 +1134,3 @@ class WorkoutStatsTestNew(TestCase):
|
||||
response = self.c.post('/rowers/user-analysis-select/',form_data)
|
||||
|
||||
self.assertEqual(response.status_code,200)
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ class WorkoutViewTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -611,4 +611,3 @@ class WorkoutViewTest(TestCase):
|
||||
self.assertRedirects(response,
|
||||
expected_url=expected_url,
|
||||
status_code=302,target_status_code=200)
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ class SimpleViewTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='basic')
|
||||
|
||||
@@ -59,4 +59,3 @@ class SimpleViewTest(TestCase):
|
||||
self.assertRedirects(response,
|
||||
expected_url='/rowers/list-workouts/',
|
||||
status_code=302,target_status_code=200)
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ class CoursesTest(TestCase):
|
||||
self.u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
)
|
||||
@@ -78,4 +78,3 @@ class CoursesTest(TestCase):
|
||||
response.get('Content-Disposition'),
|
||||
'attachment; filename="course_1.kml"'
|
||||
)
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ class OTWCPChartTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,sex='male',
|
||||
gdproptin=True,surveydone=True,sex='male',
|
||||
weightcategory='hwt',
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
@@ -113,7 +113,7 @@ class CPChartTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,sex='male',
|
||||
gdproptin=True,surveydone=True,sex='male',
|
||||
weightcategory='hwt',
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
@@ -322,5 +322,3 @@ class CPChartTest(TestCase):
|
||||
|
||||
response = self.c.get(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
|
||||
|
||||
|
||||
@@ -12,14 +12,14 @@ class EmailUpload(TestCase):
|
||||
u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
r = Rower.objects.create(user=u,gdproptin=True,
|
||||
r = Rower.objects.create(user=u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
self.theadmin = UserFactory(is_staff=True)
|
||||
self.rtheadmin = Rower.objects.create(user=self.theadmin,
|
||||
birthdate = faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -73,14 +73,14 @@ class ZipEmailUpload(TestCase):
|
||||
u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
r = Rower.objects.create(user=u,gdproptin=True,
|
||||
r = Rower.objects.create(user=u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
self.theadmin = UserFactory(is_staff=True)
|
||||
self.rtheadmin = Rower.objects.create(user=self.theadmin,
|
||||
birthdate = faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -135,14 +135,14 @@ class EmailUniCodeUpload(TestCase):
|
||||
u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
r = Rower.objects.create(user=u,gdproptin=True,
|
||||
r = Rower.objects.create(user=u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
self.theadmin = UserFactory(is_staff=True)
|
||||
self.rtheadmin = Rower.objects.create(user=self.theadmin,
|
||||
birthdate = faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -196,14 +196,14 @@ class EmailBikeErgUpload(TestCase):
|
||||
u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
r = Rower.objects.create(user=u,gdproptin=True,
|
||||
r = Rower.objects.create(user=u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
self.theadmin = UserFactory(is_staff=True)
|
||||
self.rtheadmin = Rower.objects.create(user=self.theadmin,
|
||||
birthdate = faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -257,14 +257,14 @@ class EmailBikeUpload(TestCase):
|
||||
u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
r = Rower.objects.create(user=u,gdproptin=True,
|
||||
r = Rower.objects.create(user=u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
self.theadmin = UserFactory(is_staff=True)
|
||||
self.rtheadmin = Rower.objects.create(user=self.theadmin,
|
||||
birthdate = faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -321,14 +321,14 @@ class EmailTests(TestCase):
|
||||
u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
r = Rower.objects.create(user=u,gdproptin=True,
|
||||
r = Rower.objects.create(user=u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
self.theadmin = UserFactory(is_staff=True)
|
||||
self.rtheadmin = Rower.objects.create(user=self.theadmin,
|
||||
birthdate = faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -404,7 +404,7 @@ class EmailAdminUpload(TestCase):
|
||||
u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
r = Rower.objects.create(user=u,gdproptin=True,
|
||||
r = Rower.objects.create(user=u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
birthdate = faker.profile()['birthdate']
|
||||
)
|
||||
@@ -412,7 +412,7 @@ class EmailAdminUpload(TestCase):
|
||||
self.theadmin = UserFactory(is_staff=True)
|
||||
self.rtheadmin = Rower.objects.create(user=self.theadmin,
|
||||
birthdate = faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -473,4 +473,3 @@ race 1
|
||||
result = results[0]
|
||||
|
||||
self.assertTrue(result.coursecompleted)
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ class EmpowerTest(TestCase):
|
||||
'sander@ds.ds',
|
||||
'koeinsloot',
|
||||
)
|
||||
r = Rower.objects.create(user=u,rowerplan='coach',gdproptin=True,
|
||||
r = Rower.objects.create(user=u,rowerplan='coach',gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now())
|
||||
self.c = Client()
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@ class WorkoutViewTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
showfavoritechartnotes=True)
|
||||
|
||||
@@ -22,7 +22,7 @@ class C2Objects(DjangoTestCase):
|
||||
self.u.first_name = 'John'
|
||||
self.u.last_name = 'Sander'
|
||||
self.u.save()
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
@@ -157,7 +157,7 @@ class C2ObjectsTokenExpired(DjangoTestCase):
|
||||
self.u.first_name = 'John'
|
||||
self.u.last_name = 'Sander'
|
||||
self.u.save()
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
@@ -236,7 +236,7 @@ class StravaObjects(DjangoTestCase):
|
||||
self.u.first_name = 'John'
|
||||
self.u.last_name = 'Sander'
|
||||
self.u.save()
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
@@ -342,7 +342,7 @@ class STObjects(DjangoTestCase):
|
||||
self.u.first_name = 'John'
|
||||
self.u.last_name = 'Sander'
|
||||
self.u.save()
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
@@ -490,7 +490,7 @@ class RunKeeperObjects(DjangoTestCase):
|
||||
self.u.first_name = 'John'
|
||||
self.u.last_name = 'Sander'
|
||||
self.u.save()
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
@@ -583,7 +583,7 @@ class UAObjects(DjangoTestCase):
|
||||
self.u.first_name = 'John'
|
||||
self.u.last_name = 'Sander'
|
||||
self.u.save()
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
@@ -686,7 +686,7 @@ class TPObjects(DjangoTestCase):
|
||||
self.u.first_name = 'John'
|
||||
self.u.last_name = 'Sander'
|
||||
self.u.save()
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
@@ -769,7 +769,7 @@ class AutoExportTests(TestCase):
|
||||
u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
r = Rower.objects.create(user=u,gdproptin=True,
|
||||
r = Rower.objects.create(user=u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ class InteractiveChartTest(TestCase):
|
||||
u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
r = Rower.objects.create(user=u,gdproptin=True,
|
||||
r = Rower.objects.create(user=u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
self.nu = datetime.datetime.now()
|
||||
@@ -137,5 +137,3 @@ class InteractiveChartTest(TestCase):
|
||||
res = iplots.interactive_flex_chart2(self.wote.id,promember=1,
|
||||
xparam='distance',
|
||||
yparam1='pace',yparam2='spm')
|
||||
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ class WorkoutTests(TestCase):
|
||||
self.u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
nu = datetime.datetime.now()
|
||||
@@ -37,7 +37,7 @@ class C2Tests(TestCase):
|
||||
self.u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
self.nu = datetime.datetime.now()
|
||||
@@ -77,6 +77,3 @@ class subroutinetests(TestCase):
|
||||
jsond = json.dumps(data)
|
||||
data = c2stuff.createc2workoutdata_as_splits(w)
|
||||
jsond = json.dumps(data)
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -44,7 +44,7 @@ class NewUserRegistrationTest(TestCase):
|
||||
response = self.c.post('/rowers/register/', form_data, follow=True)
|
||||
|
||||
self.assertRedirects(response,
|
||||
expected_url='/rowers/me/gdpr-optin/?next=/rowers/list-workouts/',
|
||||
expected_url='/rowers/survey/?next=/rowers/list-workouts/',
|
||||
status_code=302,target_status_code=200)
|
||||
|
||||
|
||||
@@ -84,6 +84,3 @@ class NewUserRegistrationTest(TestCase):
|
||||
self.assertRedirects(response,
|
||||
expected_url='/login/',
|
||||
status_code=302,target_status_code=200)
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -64,7 +64,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -122,7 +122,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -185,7 +185,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -251,7 +251,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -289,7 +289,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -329,7 +329,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -350,7 +350,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -396,7 +396,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -441,7 +441,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -486,7 +486,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -536,7 +536,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -581,7 +581,7 @@ class PaymentTest(TestCase):
|
||||
u = UserFactory()
|
||||
r = Rower.objects.create(user=u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
paymentprocessor='braintree',
|
||||
@@ -620,4 +620,3 @@ class PaymentTest(TestCase):
|
||||
self.assertRedirects(response,
|
||||
expected_url = '/rowers/downgradecompleted/',
|
||||
status_code=302,target_status_code=200)
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ class PermissionsFreeCoach(TestCase):
|
||||
self.ufreecoach = UserFactory(username='coachuser')
|
||||
self.rfreecoach = Rower.objects.create(user=self.ufreecoach,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='freecoach',clubsize=100)
|
||||
|
||||
self.coachinggroup = CoachingGroup.objects.create()
|
||||
@@ -37,7 +37,7 @@ class PermissionsFreeCoach(TestCase):
|
||||
self.uplan = UserFactory(username='planuser')
|
||||
self.rplan = Rower.objects.create(user=self.uplan,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='plan')
|
||||
|
||||
self.uplan_workouts = WorkoutFactory.create_batch(5, user=self.rplan)
|
||||
@@ -49,7 +49,7 @@ class PermissionsFreeCoach(TestCase):
|
||||
self.upro = UserFactory(username='prouser')
|
||||
self.rpro = Rower.objects.create(user=self.upro,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='pro')
|
||||
|
||||
self.upro_workouts = WorkoutFactory.create_batch(5, user=self.rpro)
|
||||
@@ -61,7 +61,7 @@ class PermissionsFreeCoach(TestCase):
|
||||
self.uplan2 = UserFactory(username='planuser2')
|
||||
self.rplan2 = Rower.objects.create(user=self.uplan2,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='plan')
|
||||
|
||||
self.uplan2_workouts = WorkoutFactory.create_batch(5, user=self.rplan2)
|
||||
@@ -73,7 +73,7 @@ class PermissionsFreeCoach(TestCase):
|
||||
self.upro2 = UserFactory(username='prouser2')
|
||||
self.rpro2 = Rower.objects.create(user=self.upro2,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='pro')
|
||||
|
||||
self.upro2_workouts = WorkoutFactory.create_batch(5, user=self.rpro2)
|
||||
@@ -85,7 +85,7 @@ class PermissionsFreeCoach(TestCase):
|
||||
self.ubasic = UserFactory(username='basicuser')
|
||||
self.rbasic = Rower.objects.create(user=self.ubasic,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='basic')
|
||||
|
||||
self.ubasic_workouts = WorkoutFactory.create_batch(5, user=self.rbasic)
|
||||
@@ -201,7 +201,7 @@ class PermissionsBasicsTests(TestCase):
|
||||
self.ucoach = UserFactory(username='coachuser')
|
||||
self.rcoach = Rower.objects.create(user=self.ucoach,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='coach',clubsize=10)
|
||||
|
||||
self.ucoach_workouts = WorkoutFactory.create_batch(5, user=self.rcoach)
|
||||
@@ -216,7 +216,7 @@ class PermissionsBasicsTests(TestCase):
|
||||
self.uplan = UserFactory(username='planuser')
|
||||
self.rplan = Rower.objects.create(user=self.uplan,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='plan')
|
||||
|
||||
self.uplan_workouts = WorkoutFactory.create_batch(5, user=self.rplan)
|
||||
@@ -228,7 +228,7 @@ class PermissionsBasicsTests(TestCase):
|
||||
self.upro = UserFactory(username='prouser')
|
||||
self.rpro = Rower.objects.create(user=self.upro,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='pro')
|
||||
|
||||
self.upro_workouts = WorkoutFactory.create_batch(5, user=self.rpro)
|
||||
@@ -240,7 +240,7 @@ class PermissionsBasicsTests(TestCase):
|
||||
self.uplan2 = UserFactory(username='planuser2')
|
||||
self.rplan2 = Rower.objects.create(user=self.uplan2,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='plan')
|
||||
|
||||
self.uplan2_workouts = WorkoutFactory.create_batch(5, user=self.rplan2)
|
||||
@@ -252,7 +252,7 @@ class PermissionsBasicsTests(TestCase):
|
||||
self.upro2 = UserFactory(username='prouser2')
|
||||
self.rpro2 = Rower.objects.create(user=self.upro2,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='pro')
|
||||
|
||||
self.upro2_workouts = WorkoutFactory.create_batch(5, user=self.rpro2)
|
||||
@@ -264,7 +264,7 @@ class PermissionsBasicsTests(TestCase):
|
||||
self.ubasic = UserFactory(username='basicuser')
|
||||
self.rbasic = Rower.objects.create(user=self.ubasic,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='basic')
|
||||
|
||||
self.ubasic_workouts = WorkoutFactory.create_batch(5, user=self.rbasic)
|
||||
@@ -461,7 +461,7 @@ class PermissionsViewTests(TestCase):
|
||||
self.ucoach = UserFactory(username='coachuser')
|
||||
self.rcoach = Rower.objects.create(user=self.ucoach,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='coach',clubsize=10)
|
||||
|
||||
self.ucoach_workouts = WorkoutFactory.create_batch(5, user=self.rcoach)
|
||||
@@ -476,7 +476,7 @@ class PermissionsViewTests(TestCase):
|
||||
self.uplan = UserFactory(username='planuser')
|
||||
self.rplan = Rower.objects.create(user=self.uplan,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='plan')
|
||||
|
||||
self.uplan_workouts = WorkoutFactory.create_batch(5, user=self.rplan)
|
||||
@@ -488,7 +488,7 @@ class PermissionsViewTests(TestCase):
|
||||
self.upro = UserFactory(username='prouser')
|
||||
self.rpro = Rower.objects.create(user=self.upro,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='pro')
|
||||
|
||||
self.upro_workouts = WorkoutFactory.create_batch(5, user=self.rpro)
|
||||
@@ -500,7 +500,7 @@ class PermissionsViewTests(TestCase):
|
||||
self.uplan2 = UserFactory(username='planuser2')
|
||||
self.rplan2 = Rower.objects.create(user=self.uplan2,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='plan')
|
||||
|
||||
self.uplan2_workouts = WorkoutFactory.create_batch(5, user=self.rplan2)
|
||||
@@ -512,7 +512,7 @@ class PermissionsViewTests(TestCase):
|
||||
self.upro2 = UserFactory(username='prouser2')
|
||||
self.rpro2 = Rower.objects.create(user=self.upro2,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='pro')
|
||||
|
||||
self.upro2_workouts = WorkoutFactory.create_batch(5, user=self.rpro2)
|
||||
@@ -524,7 +524,7 @@ class PermissionsViewTests(TestCase):
|
||||
self.ubasic = UserFactory(username='basicuser')
|
||||
self.rbasic = Rower.objects.create(user=self.ubasic,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='basic')
|
||||
|
||||
self.ubasic_workouts = WorkoutFactory.create_batch(5, user=self.rbasic)
|
||||
@@ -1215,7 +1215,7 @@ class PermissionsCoachingTests(TestCase):
|
||||
self.ucoach = UserFactory(username='coachuser')
|
||||
self.rcoach = Rower.objects.create(user=self.ucoach,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='coach',clubsize=10)
|
||||
|
||||
self.ucoach_workouts = WorkoutFactory.create_batch(5, user=self.rcoach)
|
||||
@@ -1230,7 +1230,7 @@ class PermissionsCoachingTests(TestCase):
|
||||
self.uplan = UserFactory(username='planuser')
|
||||
self.rplan = Rower.objects.create(user=self.uplan,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='plan')
|
||||
|
||||
self.uplan_workouts = WorkoutFactory.create_batch(5, user=self.rplan)
|
||||
@@ -1242,7 +1242,7 @@ class PermissionsCoachingTests(TestCase):
|
||||
self.upro = UserFactory(username='prouser')
|
||||
self.rpro = Rower.objects.create(user=self.upro,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='pro')
|
||||
|
||||
self.upro_workouts = WorkoutFactory.create_batch(5, user=self.rpro)
|
||||
@@ -1254,7 +1254,7 @@ class PermissionsCoachingTests(TestCase):
|
||||
self.uplan2 = UserFactory(username='planuser2')
|
||||
self.rplan2 = Rower.objects.create(user=self.uplan2,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='plan')
|
||||
|
||||
self.uplan2_workouts = WorkoutFactory.create_batch(5, user=self.rplan2)
|
||||
@@ -1266,7 +1266,7 @@ class PermissionsCoachingTests(TestCase):
|
||||
self.upro2 = UserFactory(username='prouser2')
|
||||
self.rpro2 = Rower.objects.create(user=self.upro2,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='pro')
|
||||
|
||||
self.upro2_workouts = WorkoutFactory.create_batch(5, user=self.rpro2)
|
||||
@@ -1278,7 +1278,7 @@ class PermissionsCoachingTests(TestCase):
|
||||
self.ubasic = UserFactory(username='basicuser')
|
||||
self.rbasic = Rower.objects.create(user=self.ubasic,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=True,gdproptindate=timezone.now(),
|
||||
rowerplan='basic')
|
||||
|
||||
self.ubasic_workouts = WorkoutFactory.create_batch(5, user=self.rbasic)
|
||||
|
||||
@@ -17,7 +17,7 @@ class TrainingPlanTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -175,7 +175,7 @@ class SessionLinkTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -348,7 +348,7 @@ class SessionCompleteTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -603,7 +603,7 @@ class ChallengeCompleteTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -827,7 +827,7 @@ class MandatoryTestCompleteTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -1040,7 +1040,7 @@ class PlannedSessionsView(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
self.r.save()
|
||||
@@ -1049,7 +1049,7 @@ class PlannedSessionsView(TestCase):
|
||||
self.u2 = UserFactory(username='testbasicuser')
|
||||
self.r2 = Rower.objects.create(user=self.u2,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='basic')
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ class TrialsTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='basic')
|
||||
|
||||
@@ -64,6 +64,3 @@ class TrialsTest(TestCase):
|
||||
self.assertEqual(hasplannedsessions(self.u),True)
|
||||
self.assertEqual(iscoachmember(self.u),False)
|
||||
self.assertEqual(ispromember(self.u),True)
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ class DataTest(TestCase):
|
||||
u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
r = Rower.objects.create(user=u,gdproptin=True,
|
||||
r = Rower.objects.create(user=u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now()
|
||||
)
|
||||
self.nu = datetime.datetime.now()
|
||||
|
||||
@@ -36,7 +36,7 @@ class SimpleViewTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ class PlotTests(TestCase):
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
r = Rower.objects.create(user=u,
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='basic')
|
||||
self.nu = datetime.datetime.now()
|
||||
|
||||
@@ -41,7 +41,7 @@ class TeamTest(TestCase):
|
||||
|
||||
r = Rower.objects.create(
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
user=u,
|
||||
@@ -264,7 +264,7 @@ class TeamTestLowLevel(TestCase):
|
||||
|
||||
r = Rower.objects.create(
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
user=u,
|
||||
@@ -353,5 +353,3 @@ class TeamTestLowLevel(TestCase):
|
||||
# cannot create invite for team you don't manage
|
||||
id, comment = create_invite(self.t, self.users[3],self.users[4])
|
||||
self.assertEqual(id,0)
|
||||
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@ class ForceUnits(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
@@ -164,7 +164,7 @@ class TestForceUnit(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ class ViewTest(TestCase):
|
||||
self.u = User.objects.create_user('john',
|
||||
'sander@ds.ds',
|
||||
'koeinsloot')
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,
|
||||
self.r = Rower.objects.create(user=self.u,gdproptin=True,surveydone=True,
|
||||
gdproptindate=timezone.now(),
|
||||
rowerplan='coach',
|
||||
)
|
||||
@@ -783,4 +783,3 @@ class ViewTest(TestCase):
|
||||
os.remove(f_to_be_deleted+'.gz')
|
||||
except (FileNotFoundError,OSError):
|
||||
pass
|
||||
|
||||
|
||||
@@ -80,8 +80,8 @@ class UserPreferencesTest(TestCase):
|
||||
|
||||
self.r = Rower.objects.create(user=self.u,
|
||||
birthdate=faker.profile()['birthdate'],
|
||||
gdproptin=True,
|
||||
gdproptindate=timezone.now(),
|
||||
gdproptin=True,surveydone=Trueoptin=True,
|
||||
gdproptin=True,surveydone=Trueoptindate=timezone.now(),
|
||||
rowerplan='coach')
|
||||
|
||||
self.c = Client()
|
||||
@@ -245,5 +245,3 @@ class UserPreferencesTest(TestCase):
|
||||
|
||||
response = self.c.post(url,form_data)
|
||||
self.assertEqual(response.status_code,200)
|
||||
|
||||
|
||||
|
||||
@@ -97,8 +97,8 @@ MIDDLEWARE = [
|
||||
'django.contrib.messages.middleware.MessageMiddleware',
|
||||
'django.middleware.clickjacking.XFrameOptionsMiddleware',
|
||||
'tz_detect.middleware.TimezoneMiddleware',
|
||||
'rowers.middleware.GDPRMiddleWare',
|
||||
'rowers.middleware.SurveyMiddleWare',
|
||||
'rowers.middleware.GDPRMiddleWare',
|
||||
'rowers.middleware.PowerTimeFitnessMetricMiddleWare',
|
||||
'rowers.middleware.RowerPlanMiddleWare',
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user