more complex flatmap test