Fix linalg tests after change in srand function