Private
Public Access
1
0

is session complete test

This commit is contained in:
Sander Roosendaal
2019-01-31 22:54:11 +01:00
parent f56cf7c930
commit f5eb97b13b
8 changed files with 4786 additions and 5 deletions

View File

@@ -78,8 +78,11 @@ def get_random_file(filename='rowers/tests/testdata/testdata.csv',name=''):
frm = inspect.stack()[3]
mod = inspect.getmodule(frm[0])
fromstring = 'test_%s_' % mod.__name__
try:
fromstring = 'test_%s_' % mod.__name__
except AttributeError:
fromstring = 'none_'
row = rdata(filename)
totaldist = row.df['cum_dist'].max()
totaltime = row.df['TimeStamp (sec)'].max()-row.df['TimeStamp (sec)'].min()
@@ -94,8 +97,8 @@ def get_random_file(filename='rowers/tests/testdata/testdata.csv',name=''):
duration = "%s:%s:%s.%s" % (hours,minutes,seconds,tenths)
duration = datetime.time(hour=hours,minute=minutes,second=seconds)
workoutdate = row.rowdatetime.strftime('%Y-%m-%d')
workoutstarttime = row.rowdatetime.strftime('%H:%M:%S')
workoutdate = row.rowdatetime.date()
workoutstarttime = row.rowdatetime
extension = filename[-3:]