[multi-part] Enabled bidirectional sorting

* Add functional tests for sorting

Change-Id: I35b04712f6269b056cf8c3dcc615f558250fcd35
4 files changed