Earlier quoted context omitted.
What's your definition of "pure function". Apparently not "pure function" in the sense of "pure functional programming", because if that were so, your claim would just be wrong. Counterexample: "printToConsole: IO[null]": is a pure function but still not easy to test.
The definition of "pure function" I'm familiar with from functional programming has no side effects including I/O. Assuming 'printToConsole' is performing I/O, you're describing a impure function.
I recommend you to have a look at Haskell, probably the most famous language for enforcing only pure functions in your program. And I took this example from Haskell.
Here is a good starting point for this concrete example: > https://stackoverflow.com/questions/59035420/understanding-p...
Quote (from the course 'Haskell Fundamentals Part 1' mentioned in the post):
> This example helps illustrate that putStrLn is not a function with side effects.
The answers explain the concept quite well.