@@ -438,8 +438,10 @@ def test_get_lowest_y_real_fail(self):
438438 initial_guess = 1.0j * numpy .random .rand (dimension , n_lowest )
439439 numpy .random .seed (dimension * 2 )
440440 initial_guess += numpy .random .rand (dimension , n_lowest )
441- with pytest .warns (RuntimeWarning , match = ("Unable to get real only eigenvectors"
442- "|Initial guess is not real only!" )):
441+ with pytest .warns (
442+ RuntimeWarning ,
443+ match = ("Unable to get real only eigenvectors" "|Initial guess is not real only!" ),
444+ ):
443445 success , _ , eigen_vectors = davidson .get_lowest_n (
444446 n_lowest , initial_guess , max_iterations = 10
445447 )
@@ -462,8 +464,10 @@ def test_get_lowest_y_real(self):
462464 initial_guess = 1.0j * numpy .random .rand (dimension , n_lowest )
463465 numpy .random .seed (dimension * 2 )
464466 initial_guess += numpy .random .rand (dimension , n_lowest )
465- with pytest .warns (RuntimeWarning , match = ("Unable to get real only eigenvectors"
466- "|Initial guess is not real only!" )):
467+ with pytest .warns (
468+ RuntimeWarning ,
469+ match = ("Unable to get real only eigenvectors" "|Initial guess is not real only!" ),
470+ ):
467471 success , eigen_values , eigen_vectors = davidson .get_lowest_n (
468472 n_lowest , initial_guess , max_iterations = 10
469473 )
@@ -493,8 +497,10 @@ def test_get_lowest_y_complex(self):
493497 initial_guess = 1.0j * numpy .random .rand (dimension , n_lowest )
494498 numpy .random .seed (dimension * 2 )
495499 initial_guess += numpy .random .rand (dimension , n_lowest )
496- with pytest .warns (RuntimeWarning , match = ("Unable to get real only eigenvectors"
497- "|Initial guess is not real only!" )):
500+ with pytest .warns (
501+ RuntimeWarning ,
502+ match = ("Unable to get real only eigenvectors" "|Initial guess is not real only!" ),
503+ ):
498504 success , eigen_values , eigen_vectors = davidson .get_lowest_n (
499505 n_lowest , initial_guess , max_iterations = 10
500506 )
0 commit comments