passing all tests
This commit is contained in:
@@ -84,7 +84,7 @@
|
|||||||
{{ field.as_hidden }}
|
{{ field.as_hidden }}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
<p>
|
<p>
|
||||||
<input class="button green" type="submit" value="Save">
|
<input type="submit" value="Save">
|
||||||
</p>
|
</p>
|
||||||
<span>
|
<span>
|
||||||
<a href="">Reset to last saved</a>
|
<a href="">Reset to last saved</a>
|
||||||
|
|||||||
@@ -64,7 +64,7 @@
|
|||||||
{{ inviteform.as_table }}
|
{{ inviteform.as_table }}
|
||||||
</table>
|
</table>
|
||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
<input class="button green" type="submit" value="Submit">
|
<input type="submit" value="Submit">
|
||||||
</form>
|
</form>
|
||||||
{% else %}
|
{% else %}
|
||||||
<p>
|
<p>
|
||||||
|
|||||||
@@ -271,21 +271,21 @@ class URLTests(TestCase):
|
|||||||
|
|
||||||
html = BeautifulSoup(response.content,'html.parser')
|
html = BeautifulSoup(response.content,'html.parser')
|
||||||
|
|
||||||
if 'restore' in url:
|
|
||||||
print html.find_all('a')
|
|
||||||
|
|
||||||
urls = [a['href'] for a in html.find_all('a')]
|
urls = [a['href'] for a in html.find_all('a')]
|
||||||
|
|
||||||
|
|
||||||
for u in urls:
|
for u in urls:
|
||||||
if u not in tested and 'rowers' in u and 'http' not in u and 'authorize' not in u and 'import' not in u and 'logout' not in u:
|
if u not in tested and 'rowers' in u and 'http' not in u and 'authorize' not in u and 'import' not in u and 'logout' not in u:
|
||||||
response = self.c.get(u)
|
response2 = self.c.get(u)
|
||||||
if response.status_code not in [200,302]:
|
if response2.status_code not in [200,302]:
|
||||||
print(len(tested))
|
print(len(tested))
|
||||||
|
print(response.templates[0].name)
|
||||||
print(url)
|
print(url)
|
||||||
print(u)
|
print(u)
|
||||||
print(response.status_code)
|
print(response.status_code)
|
||||||
tested.append(u)
|
tested.append(u)
|
||||||
self.assertIn(response.status_code,
|
self.assertIn(response2.status_code,
|
||||||
[200,302])
|
[200,302])
|
||||||
else:
|
else:
|
||||||
tested.append(u)
|
tested.append(u)
|
||||||
|
|||||||
BIN
rowers/tests/testdata/testdata.csv.gz
vendored
BIN
rowers/tests/testdata/testdata.csv.gz
vendored
Binary file not shown.
@@ -4706,7 +4706,7 @@ def workout_summary_edit_view(request,id,message="",successmessage=""
|
|||||||
'name':'Workouts'
|
'name':'Workouts'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
'url':get_workout_default_page(request,row.id),
|
'url':get_workout_default_page(request,encoder.encode_hex(row.id)),
|
||||||
'name': row.name
|
'name': row.name
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user