TST: fix spurious test failure in linalg.  Closes gh-2945.