Extended document service test class and implemented delete flag functionality