Only redirect when redirect url is an internal page.
This commit is contained in:
@@ -65,7 +65,7 @@ def log_in(username, password):
|
||||
|
||||
@world.absorb
|
||||
def register_by_course_id(course_id, is_staff=False):
|
||||
create_user('robot')
|
||||
create_user('robot', 'password')
|
||||
u = User.objects.get(username='robot')
|
||||
if is_staff:
|
||||
u.is_staff = True
|
||||
|
||||
@@ -168,6 +168,11 @@ def dialogs_are_closed(step):
|
||||
assert world.dialogs_closed()
|
||||
|
||||
|
||||
@step(u'visit the url "([^"]*)"')
|
||||
def visit_url(step, url):
|
||||
world.browser.visit(django_url(url))
|
||||
|
||||
|
||||
@step('I will confirm all alerts')
|
||||
def i_confirm_all_alerts(step):
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user