#NEWLINE# def test_sparsity_always_has_diagonal_space( self , backend ) : #NEWLINE# #INDENT# s = op2 . Set ( 1 ) #NEWLINE# d = op2 . Set ( 4 ) #NEWLINE# m = op2 . Map ( s , d , 1 , [ 2 ] ) #NEWLINE# d2 = op2 . Set ( 5 ) #NEWLINE# m2 = op2 . Map ( s , d2 , 2 , [ 1 , 4 ] ) #NEWLINE# sparsity = op2 . Sparsity ( ( d , d2 ) , ( m , m2 ) ) #NEWLINE# assert all ( ( sparsity . nnz == [ 1 , 1 , 3 , 1 ] ) )