Add a test to flatten an item twice, with an operation in the middle