Improved patch and new tests
Patch next