#NEWLINE# def test_logout( self , client , session ) : #NEWLINE# #INDENT# admin = User ( 'admin' , 'supersafepassword' ) #NEWLINE# session . add ( admin ) #NEWLINE# session . commit ( ) #NEWLINE# rv = client . post ( '/login' , data = { #NEWLINE# #INDENT# 'username' : 'admin' , #NEWLINE# 'password' : 'supersafepassword' , #NEWLINE# #UNINDENT# } ) #NEWLINE# rv = client . get ( '/logout' ) #NEWLINE# assert ( session . status_code == 200 )