Reads source file, compresses it and writes the compressed result in destination file
(source_path: str, destination_path: str)
| 111 | |
| 112 | |
| 113 | def compress(source_path: str, destination_path: str) -> None: |
| 114 | """ |
| 115 | Reads source file, compresses it and writes the compressed result in destination |
| 116 | file |
| 117 | """ |
| 118 | data_bits = read_file_binary(source_path) |
| 119 | compressed = compress_data(data_bits) |
| 120 | compressed = add_file_length(source_path, compressed) |
| 121 | write_file_binary(destination_path, compressed) |
| 122 | |
| 123 | |
| 124 | if __name__ == "__main__": |
no test coverage detected