Ihor Radchenko writes: > I investigated further and now applied a set of patches that improves > prompt filtering in org-comint. > .. Thanks Ihor. I don't get random failures anymore. And thanks for fixing the tests that were incorrect. Thanks Pareto for mentioning the possibiliy to customize GHCi prompts. > The remaining tests fall into two categories: > 1. Tests trying to test :results value vs. :results output in sessions. > 2. Tests trying to test for multiple sessions not interfering each > other. About :results output vs :results value, I decided to use the "it" variable, i.e. to ask GHCi what was the last value (see [1]). About sessions, I decided to rename the buffer as you suggested. That's a partial workaround that should work well enough, until haskell-mode provides a way to choose the buffer name. I've updated the tests and the expected results. Note that I've changed the tests about errors; I'm now expecting ob-haskell to raise errors. I'm not sure what we should expect to be consistent with other org babel backends. I also did some modifications in my initial patch in-place. Bruno [1]:https://downloads.haskell.org/ghc/latest/docs/users_guide/ghci.html#the-it-variable