More fixes to tests

skala
ywarnier 14 years ago
parent eac5f433a3
commit d529235a1e
  1. 8
      tests/main/inc/lib/fileUpload.lib.test.php

@ -100,7 +100,7 @@ class TestFileUpload extends UnitTestCase {
function testBuildMissingFilesForm() { function testBuildMissingFilesForm() {
global $_course; global $_course;
$missing_files = array(); $missing_files = array();
$upload_path=api_get_path(SYS_COURSE_PATH).'document/image'; $upload_path=api_get_path(SYS_CODE_PATH).'default_course_document/images';
$file_name = 'board.jpg'; $file_name = 'board.jpg';
$res=build_missing_files_form($missing_files,$upload_path,$file_name); $res=build_missing_files_form($missing_files,$upload_path,$file_name);
$this->assertTrue(is_string($res)); $this->assertTrue(is_string($res));
@ -118,11 +118,9 @@ class TestFileUpload extends UnitTestCase {
//space //space
function testDirTotalSpace() { function testDirTotalSpace() {
$dirPath= api_get_path(SYS_COURSE_PATH).'document/'; $dirPath= api_get_path(SYS_CODE_PATH).'default_course_document/images';
$res= dir_total_space($dirPath); $res= dir_total_space($dirPath);
if(!is_string($res)) { $this->assertTrue($res>0,'The default_course_document/images dir should be larger than 0 bytes');
$this->assertTrue(is_numeric($res));
}
} }
//filter //filter

Loading…
Cancel
Save