`assert_eq(A == B, true)`? `assert_eq(A, B)`, or even `assert(A == B)` by all means.
And this does not really explain what a `Ket` is, rather unfortunately. I now know it's a pair of complex numbers, but that's not very handy - and the `is_valid` definition is not explained, so I don't even get told what subset of pairs of complex numbers make up valid kets without reading code.