Skip to content
This repository was archived by the owner on Sep 10, 2021. It is now read-only.

Commit f42525b

Browse files
committed
BUG: refs #0352. Fix test so it won't collide with changes in next
1 parent 92209cf commit f42525b

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

core/controllers/UploadController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ public function saveuploadedAction()
246246
if($this->isTestingEnv())
247247
{
248248
//simulate file upload
249-
$path = $this->_getParam('path');
249+
$path = $this->_getParam('testpath');
250250
$filename = basename($path);
251251
$file_size = filesize($path);
252252
}

core/tests/controllers/UploadDownloadControllerTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ function testSaveuploadedAction()
176176
$this->params = array();
177177
$this->params['parent'] = $userDao->getPublicFolder()->getKey();
178178
$this->params['license'] = 0;
179-
$this->params['path'] = BASE_PATH.'/tests/testfiles/search.png'; //testing mode param
179+
$this->params['testpath'] = BASE_PATH.'/tests/testfiles/search.png'; //testing mode param
180180
$this->dispatchUrI('/upload/saveuploaded', $userDao);
181181

182182
$search = $this->Item->getItemsFromSearch('search.png', $userDao);
@@ -186,7 +186,7 @@ function testSaveuploadedAction()
186186
$this->resetAll();
187187
$this->params['parent'] = $userDao->getPublicFolder()->getKey();
188188
$this->params['license'] = 0;
189-
$this->params['path'] = BASE_PATH.'/tests/testfiles/empty.txt'; //testing mode param
189+
$this->params['testpath'] = BASE_PATH.'/tests/testfiles/empty.txt'; //testing mode param
190190
$this->dispatchUrI('/upload/saveuploaded', $userDao);
191191

192192
$search = $this->Item->getItemsFromSearch('empty.txt', $userDao);

0 commit comments

Comments
 (0)