Media library item validation, persistence and deletion in media service with tests.