Skip to content

Skip upload_2G.phpt if disk_free_space() <= 2GB #5873

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions sapi/cli/tests/upload_2G.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ if (PHP_INT_SIZE < 8) {
die("skip need PHP_INT_SIZE>=8");
}

if (disk_free_space(sys_get_temp_dir()) < 2300000000) {
die("skip need more than 2.15G of free disk space for the uploaded file");
}

if (!file_exists('/proc/meminfo')) {
die('skip Cannot check free RAM from /proc/meminfo on this platform');
}
Expand Down