fix trash bin expire operation and add unit tests

add unit tests for expire operation.
This SELECT is completely gone ?