protocol CompressionService {
    func compress(
        url: URL
    ) throws -> URL
}

Simple interface. More than 300 lines of code to test all the scenarios.