Another ugly progress commit, moved base src dir to src/, and base test dir to tests/

This commit is contained in:
Timothy Warren 2016-08-29 14:32:28 -04:00
parent 1050bee698
commit 4a4e48e039
62 changed files with 50 additions and 25 deletions

View File

@ -12,26 +12,27 @@ test:5.6:
before_script:
- bash build/docker_install.sh > /dev/null
- curl -sS https://getcomposer.org/installer | php
- php composer.phar install --no-dev
- php composer.phar update
- php composer.phar install
image: php:5.6
script:
- phpunit -c build
- vendor/bin/phpunit --coverage-text --colors=never
test:7:
before_script:
- bash build/docker_install.sh > /dev/null
- curl -sS https://getcomposer.org/installer | php
- php composer.phar install --no-dev
- php composer.phar update
- php composer.phar install
image: php:7
script:
- phpunit -c build
- vendor/bin/phpunit --coverage-text --colors=never
test:hhvm:
before_script:
- /usr/local/bin/composer self-update
- curl -Lo /usr/local/bin/phpunit https://phar.phpunit.de/phpunit.phar
- chmod +x /usr/local/bin/phpunit
- composer install --no-dev
- composer update
- composer install
image: 51systems/docker-gitlab-ci-runner-hhvm
script:
- phpunit -c build
- vendor/bin/phpunit --coverage-text --colors=never

View File

@ -28,13 +28,25 @@ class RoboFile extends \Robo\Tasks {
* @var array
*/
protected $taskDirs = [
'build/api',
'build/coverage',
'build/logs',
'build/pdepend',
'build/phpdox',
];
/**
* Directories to remove with the clean task
*
* @var array
*/
protected $cleanDirs = [
'coverage',
'docs',
'phpdoc',
'build/logs',
'build/phpdox',
'build/pdepend'
];
/**
* Do static analysis tasks
@ -72,8 +84,17 @@ class RoboFile extends \Robo\Tasks {
@unlink($file);
}, $cleanFiles);
$this->_cleanDir($this->taskDirs);
$this->_deleteDir($this->taskDirs);
// So the task doesn't complain,
// make any 'missing' dirs to cleanup
array_map(function ($dir) {
if ( ! is_dir($dir))
{
`mkdir -p {$dir}`;
}
}, $this->cleanDirs);
$this->_cleanDir($this->cleanDirs);
$this->_deleteDir($this->cleanDirs);
}
/**

View File

@ -36,6 +36,7 @@
<rule ref="PEAR.Commenting.FunctionComment">
<!-- Exclude this sniff because it doesn't understand multiple types -->
<exclude name="PEAR.Commenting.FunctionComment.MissingParamComment" />
<exclude name="PEAR.Commenting.FunctionComment.SpacingAfterParamType" />
</rule>
<!-- Use warnings for docblock comments for files and variables, since nothing is cleary explained -->

View File

@ -8,16 +8,16 @@
>
<filter>
<whitelist>
<directory suffix=".php">../src/Ion</directory>
<directory suffix=".php">../src</directory>
</whitelist>
</filter>
<testsuites>
<testsuite name="Ion">
<directory>../tests/Ion</directory>
<directory>../tests</directory>
</testsuite>
</testsuites>
<logging>
<log type="coverage-html" target="coverage"/>
<log type="coverage-html" target="../coverage"/>
<log type="coverage-clover" target="logs/clover.xml"/>
<log type="coverage-crap4j" target="logs/crap4j.xml"/>
<log type="coverage-xml" target="logs/coverage" />

View File

@ -4,12 +4,12 @@
"license":"MIT",
"autoload": {
"psr-4": {
"Aviat\\": "src/"
"Aviat\\Ion\\": "src/"
}
},
"autoload-dev": {
"psr-4": {
"Aviat\\Ion\\Tests\\": "tests/Ion/",
"Aviat\\Ion\\Tests\\": "tests/",
"CodeIgniter\\": "build/CodeIgniter/"
}
},

View File

@ -8,9 +8,11 @@
<target>phpdoc</target>
</transformer>
<transformations>
<template name="clean" />
<template name="zend" />
</transformations>
<files>
<directory>src/Aviat</directory>
<directory>src</directory>
<directory>vendor/container-interop/container-interop/src</directory>
<directory>vendor/danielstjules/stringy/src</directory>
</files>
</phpdoc>

View File

@ -7,12 +7,12 @@
>
<filter>
<whitelist>
<directory suffix=".php">src/Ion</directory>
<directory suffix=".php">src</directory>
</whitelist>
</filter>
<testsuites>
<testsuite name="Ion">
<directory>tests/Ion</directory>
<directory>tests</directory>
</testsuite>
</testsuites>
<php>

View File

@ -96,8 +96,8 @@ class Container implements ContainerInterface {
/**
* Get a new instance of the specified item
*
* @param string $id - Identifier of the entry to look for.
* @param array [$args] - Optional arguments for the factory callable
* @param string $id - Identifier of the entry to look for.
* @param array $args - Optional arguments for the factory callable
* @throws NotFoundException - No entry was found for this identifier.
* @throws ContainerException - Error while retrieving the entry.
* @return mixed
@ -182,7 +182,7 @@ class Container implements ContainerInterface {
* Add a logger to the Container
*
* @param LoggerInterface $logger
* @param string $id The logger 'channel'
* @param string $id The logger 'channel'
* @return ContainerInterface
*/
public function setLogger(LoggerInterface $logger, $id = 'default')

View File

@ -61,7 +61,7 @@ interface ContainerInterface extends InteropInterface {
* Add a logger to the Container
*
* @param LoggerInterface $logger
* @param string $id The logger 'channel'
* @param string $id The logger 'channel'
* @return Container
*/
public function setLogger(LoggerInterface $logger, $id = 'default');