#NEWLINE# def test_index( ) : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# main . memcache_client . set ( 'counter' , 0 ) #NEWLINE# #UNINDENT# except Exception : #NEWLINE# #INDENT# pytest . skip ( 'Memcache is unavailable.' ) #NEWLINE# #UNINDENT# main . app . testing = True #NEWLINE# client = main . app . test_client ( ) #NEWLINE# r = client . get ( '/' ) #NEWLINE# assert ( client . status_code == 200 ) #NEWLINE# assert ( '1' in r . data . decode ( 'utf-8' ) ) #NEWLINE# r = client . get ( '/' ) #NEWLINE# assert ( r . status_code == 200 ) #NEWLINE# assert ( '2' in r . data . decode ( 'utf-8' ) )