fix for some test that relied on undefined behaviour

Could cause tests to fail on windows because of NumPy compiler
and llvm producing a different result for that undefined behaviour.