#NEWLINE# def test_basics( ) : #NEWLINE# #INDENT# one = Rational ( 1 ) #NEWLINE# zero = Rational ( 0 ) #NEWLINE# assert ( array ( 1 ) == array ( one ) ) #NEWLINE# assert ( array ( [ X ] ) == array ( [ one ] ) ) #NEWLINE# assert ( array ( [ x ] ) == array ( [ x ] ) ) #NEWLINE# assert ( array ( x ) == array ( Symbol ( 'x' ) ) ) #NEWLINE# assert ( array ( ( one + x ) ) == array ( ( 1 + x ) ) ) #NEWLINE# X = array ( [ one , zero , zero ] ) #NEWLINE# assert ( X == array ( [ one , zero , zero ] ) ) . all ( ) #NEWLINE# assert ( X == array ( [ one , 0 , 0 ] ) ) . all ( )