Regression test for KT-3238. The issue itself is incorrect but test may be useful