Creating the folder when the tests run
Conflicts: build/integration/features/bootstrap/BasicStructure.php build/integration/run.sh
This commit is contained in:
parent
e8a014be34
commit
884c7a6b6b
|
@ -334,5 +334,30 @@ trait BasicStructure {
|
|||
rmdir("../../core/skeleton/PARENT");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @BeforeScenario @local_storage
|
||||
*/
|
||||
public static function removeFilesFromLocalStorageBefore(){
|
||||
$dir = "./work/local_storage/";
|
||||
$di = new RecursiveDirectoryIterator($dir, FilesystemIterator::SKIP_DOTS);
|
||||
$ri = new RecursiveIteratorIterator($di, RecursiveIteratorIterator::CHILD_FIRST);
|
||||
foreach ( $ri as $file ) {
|
||||
$file->isDir() ? rmdir($file) : unlink($file);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @AfterScenario @local_storage
|
||||
*/
|
||||
public static function removeFilesFromLocalStorageAfter(){
|
||||
$dir = "./work/local_storage/";
|
||||
$di = new RecursiveDirectoryIterator($dir, FilesystemIterator::SKIP_DOTS);
|
||||
$ri = new RecursiveIteratorIterator($di, RecursiveIteratorIterator::CHILD_FIRST);
|
||||
foreach ( $ri as $file ) {
|
||||
$file->isDir() ? rmdir($file) : unlink($file);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -36,6 +36,17 @@ echo $PHPPID_FED
|
|||
export TEST_SERVER_URL="http://localhost:$PORT/ocs/"
|
||||
export TEST_SERVER_FED_URL="http://localhost:$PORT_FED/ocs/"
|
||||
|
||||
|
||||
#Enable external storage app
|
||||
../../occ app:enable files_external
|
||||
|
||||
mkdir -p work/local_storage
|
||||
OUTPUT_CREATE_STORAGE=`../../occ files_external:create local_storage local null::null -c datadir=./build/integration/work/local_storage`
|
||||
|
||||
ID_STORAGE=`echo $OUTPUT_CREATE_STORAGE | awk {'print $5'}`
|
||||
|
||||
../../occ files_external:option $ID_STORAGE enable_sharing true
|
||||
|
||||
vendor/bin/behat -f junit -f pretty $SCENARIO_TO_RUN
|
||||
RESULT=$?
|
||||
|
||||
|
|
Loading…
Reference in New Issue