#NEWLINE# def test_sieve_invalid_mask_dtype( basic_image ) : #NEWLINE# #INDENT# ' A mask that is the wrong dtype should fail ' #NEWLINE# with Env ( ) : #NEWLINE# #INDENT# for dtype in ( 'int8' , 'int16' , 'int32' ) : #NEWLINE# #INDENT# with pytest . raises ( ValueError ) : #NEWLINE# #INDENT# sieve ( basic_image , basic_image . sum ( ) , mask = numpy . ones ( basic_image . shape , dtype = dtype ) )