Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.0.x will end 8 May 2023 (12 months).
  • Bug fixes for security issues in 4.0.x will end 13 November 2023 (18 months).
  • PHP version: minimum PHP 7.3.0 Note: the minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is also supported.

Class: zip_packer_test  - X-Ref

Unit tests for /lib/filestorage/zip_packer.php and zip_archive.php

setUp()   X-Ref


test_get_packer()   X-Ref
No description

test_list_files()   X-Ref


test_archive_to_pathname()   X-Ref


test_archive_to_storage()   X-Ref


test_extract_to_pathname()   X-Ref


test_zip_entry_path_having_folder_ending_with_dot()   X-Ref
Test functionality of {@see zip_packer} for entries with folders ending with dots.


test_extract_to_pathname_onlyfiles()   X-Ref


test_extract_to_pathname_returnvalue_successful()   X-Ref


test_extract_to_pathname_returnvalue_failure()   X-Ref


test_extract_to_storage()   X-Ref


test_add_files()   X-Ref


test_close_archive()   X-Ref
No description

test_open_archive()   X-Ref


test_open_encrypted_archive()   X-Ref
Test opening an encrypted archive


test_file_progress()   X-Ref
Tests the progress reporting.


check_progress_toward_max()   X-Ref
Checks that progress reported is numeric rather than indeterminate,
and follows the progress reporting rules.


progress($progress = file_progress::INDETERMINATE, $max = file_progress::INDETERMINATE)   X-Ref
Handles file_progress interface.

param: int $progress
param: int $max