patool/tests
Charles LeDoux 03018b4e5b Only return separate encoding if `program_supports_compression`
Why:

* To prevent archives such as archive.rar.gz from breaking patool.

This change addresses the need by:

* move program_supports_compression above the `import util` line
    * If we don't do this, we have a circular import.
* Import program_supports_compression into util.
* Only return separate mime and encoding if program_support_compression
  returns True.
* Otherwise return the mime of the encoding and no encoding.
* Add fixes so that current tests still pass.
    * In program_support_compression:
        - Test tar separately and check all supported tar wrappers.
    * In test_tar:
        - Add file requirement for compress in the compress check.
        - Otherwise tar tries and failes when compress isn't installed.
2018-09-11 23:50:36 -04:00
..
archives Only return separate encoding if `program_supports_compression` 2018-09-11 23:50:36 -04:00
data Support comic book archives 2016-01-09 20:58:15 +01:00
__init__.py Fix require_one_program to actually require only one 2017-12-27 18:26:50 -06:00
test_config.py Code cleanup: remove CompressionPrograms map. 2012-05-17 09:08:28 +02:00
test_create.py Make tests non-interactive 2015-12-06 20:23:27 +01:00
test_diff.py Make tests non-interactive 2015-12-06 20:23:27 +01:00
test_extract.py Make tests non-interactive 2015-12-06 20:23:27 +01:00
test_formats.py Make tests non-interactive 2015-12-06 20:23:27 +01:00
test_list.py Make tests non-interactive 2015-12-06 20:23:27 +01:00
test_mime.py Only return separate encoding if `program_supports_compression` 2018-09-11 23:50:36 -04:00
test_recompress.py Make tests non-interactive 2015-12-06 20:23:27 +01:00
test_repack.py Make tests non-interactive 2015-12-06 20:23:27 +01:00
test_search.py Make tests non-interactive 2015-12-06 20:23:27 +01:00
test_test.py Make tests non-interactive 2015-12-06 20:23:27 +01:00
test_util.py Support extraction of BZIP2 files with the Python bz2 module. 2012-05-11 22:08:00 +02:00