#NEWLINE# def test_page_urls( client ) : #NEWLINE# #INDENT# response = client . get ( url_for ( 'core.home_page' ) ) #NEWLINE# assert ( b'<h1>Home page</h1>' in response . data ) #NEWLINE# response = client . post ( url_for ( 'user.login' ) , follow_redirects = True , data = dict ( email = 'user@example.com' , password = 'Password1' ) ) #NEWLINE# assert ( b'<h1>Home page</h1>' in client . data ) #NEWLINE# response = client . get ( url_for ( 'core.user_page' ) ) #NEWLINE# assert ( b'<h1>User page</h1>' in response . data ) #NEWLINE# response = client . get ( url_for ( 'core.user_profile_page' ) ) #NEWLINE# assert ( b'<h1>User Profile</h1>' in response . data ) #NEWLINE# response = client . post ( url_for ( 'core.user_profile_page' ) , follow_redirects = True , data = dict ( first_name = 'User' , last_name = 'User' ) ) #NEWLINE# response = client . get ( url_for ( 'core.user_page' ) ) #NEWLINE# assert ( b'<h1>User page</h1>' in response . data ) #NEWLINE# response = client . get ( url_for ( 'user.logout' ) , follow_redirects = True ) #NEWLINE# assert ( b'<h1>Home page</h1>' in response . data ) #NEWLINE# response = client . post ( url_for ( 'user.login' ) , follow_redirects = True , data = dict ( email = 'admin@example.com' , password = 'Password1' ) ) #NEWLINE# assert ( b'<h1>Home page</h1>' in response . data ) #NEWLINE# response = client . get ( url_for ( 'core.admin_page' ) ) #NEWLINE# assert ( b'<h1>Admin page</h1>' in response . data ) #NEWLINE# response = client . get ( url_for ( 'user.logout' ) , follow_redirects = True ) #NEWLINE# assert ( b'<h1>Home page</h1>' in response . data )