-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathciunit.mod
30 lines (26 loc) · 800 Bytes
/
ciunit.mod
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
<?php
/**
* This mod adds a CIUinit/PHPUnit base install to the CI installation
*
*/
// Get the latest CI
echo "Fetching latest CIUnit from github.com/eriktorsner/ciunit....\n";
$cmd = "curl -sL https://github.com/eriktorsner/ciunit/archive/master.zip > ciunit.zip";
exec($cmd);
// unzip it
echo "Unzipping...\n";
$cmd = "unzip ciunit.zip";
exec($cmd);
// move files and folders into the CI install
$cmd = "mv ciunit-master/application/config/testing/ $ci_folder/application/config/";
exec($cmd);
$cmd = "mv ciunit-master/application/third_party/CIUnit/ $ci_folder/application/third_party/";
exec($cmd);
$cmd = "mv ciunit-master/tests/ $ci_folder/";
exec($cmd);
$cmd = "rm -rf ciunit-master/";
exec($cmd);
// Remove archive
echo "Cleaning up download\n";
$cmd = "rm -rf ciunit.zip";
exec($cmd);