#NEWLINE# def test_markdown_images( pad , builder ) : #NEWLINE# #INDENT# blog_index = pad . get ( '/blog' , page_num = 1 ) #NEWLINE# ( prog , _ ) = builder . build ( blog_index ) #NEWLINE# with prog . artifacts [ 0 ] . open ( 'rb' ) as f : #NEWLINE# #INDENT# assert ( b'This is an image <img src="../blog/2015/12/post1/logo.png" alt="logo">.' in f . read ( ) ) #NEWLINE# #UNINDENT# blog_post = pad . get ( '/blog/post1' ) #NEWLINE# ( prog , _ ) = builder . build ( blog_post ) #NEWLINE# with prog . artifacts [ 0 ] . open ( 'rb' ) as f : #NEWLINE# #INDENT# assert ( b'This is an image <img src="../../../../blog/2015/12/post1/logo.png" alt="logo">.' in f . read ( ) )