This repository has been archived by the owner on Sep 28, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathRoboFile.php
48 lines (45 loc) · 1.73 KB
/
RoboFile.php
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<?php
////////////////////////////////////////////////////////////////////////////////
// __________ __ ________ __________
// \______ \ |__ ______ / _____/ ____ _____ ______\______ \ _______ ___
// | ___/ | \\____ \/ \ ____/ __ \\__ \\_ __ \ | _// _ \ \/ /
// | | | Y \ |_> > \_\ \ ___/ / __ \| | \/ | ( <_> > <
// |____| |___| / __/ \______ /\___ >____ /__| |______ /\____/__/\_ \
// \/|__| \/ \/ \/ \/ \/
// -----------------------------------------------------------------------------
// Designed and Developed by Brad Jones <brad @="bjc.id.au" />
// -----------------------------------------------------------------------------
////////////////////////////////////////////////////////////////////////////////
/*
* Include our local composer autoloader just in case
* we are called with a globally installed version of robo.
*/
require_once(__DIR__.'/vendor/autoload.php');
class RoboFile extends Robo\Tasks
{
/**
* Runs unit tests, with code coverage report.
*/
public function test()
{
exit
(
$this->taskPHPUnit()
->arg('./tests')
->option('coverage-clover', './build/logs/clover.xml')
->run()->getExitCode()
);
}
/**
* Generates the projects documentation.
*
* This is made up of reflected information, DocBlocks
* and other human written text.
*/
public function docGenerate()
{
$this->_exec('cd '.__DIR__.'/docs && composer install');
$this->_exec(__DIR__.'/docs/build');
$this->_exec(__DIR__.'/vendor/bin/couscous preview');
}
}