Commit adaa5054 authored by Olivier Lequeux's avatar Olivier Lequeux
Browse files

refine PSRO, composer structure ans tests

parent f045e394
/vendor/
<component name="ProjectDictionaryState">
<dictionary name="olequeux">
<words>
<w>hydrators</w>
<w>lequeux</w>
</words>
</dictionary>
</component>
\ No newline at end of file
{
"name": "ccin2p3/Lavoisier",
"version": "dev-master"
"name": "ccin2p3/lavoisiercli",
"description": "Lavoisier client",
"authors": [
{
"name": "Olivier Lequeux",
"email": "olequeux@cc.in2p3.fr"
}
],
"autoload": {
"psr-4": {"": "src/"}
}
}
{
"name": "ccin2p3/lavoisier",
"version": "dev-master"
}
......@@ -9,17 +9,17 @@
processIsolation="false"
stopOnFailure="false"
syntaxCheck="false"
bootstrap="vendor/autoload.php"
>
bootstrap="./vendor/autoload.php">
<testsuites>
<testsuite name="Twig Extensions Test Suite">
<directory>./test/Twig/</directory>
<testsuite name="Lavoisier client test suite">
<directory>./tests</directory>
</testsuite>
</testsuites>
<filter>
<whitelist>
<directory suffix=".php">./lib/Twig/</directory>
<directory suffix=".php">./src/Lavoisier/</directory>
</whitelist>
</filter>
</phpunit>
<?php
namespace Lavoisier;
namespace Lavoisier\Entries;
/**
* Created by JetBrains PhpStorm.
......@@ -8,6 +8,7 @@ namespace Lavoisier;
* Date: 28/10/13
*/
const $EX_ENTRIES_XMLNS = ""
class Entries extends \ArrayObject implements IEntries
{
......
<?php
namespace Lavoisier;
namespace Lavoisier\Entries;
/**
* @author Olivier LEQUEUX
......
......@@ -2,7 +2,7 @@
namespace Lavoisier\Hydrators;
use \Lavoisier\IHydrator;
use \Lavoisier\Hydrators\IHydrator;
class DefaultHydrator implements IHydrator{
......
......@@ -2,8 +2,9 @@
namespace Lavoisier\Hydrators;
use \Lavoisier\IHydrator;
use \Lavoisier\IEntries;
use \Lavoisier\Hydrators\IHydrator;
use \Lavoisier\Entries\IEntries;
use \Lavoisier\Entries\Entries;
class EntriesHydrator implements IHydrator
{
......@@ -15,9 +16,9 @@ class EntriesHydrator implements IHydrator
public function __construct()
{
$this->value_as_key = false;
$this->rootBinding = '\Lavoisier\Entries';
$this->rootBinding = '\Lavoisier\Entries\Entries';
$this->keyBinding = array();
$this->defaultBinding = '\Lavoisier\Entries';
$this->defaultBinding = '\Lavoisier\Entries\Entries';
}
public function setValueAsKey($value_as_key)
......
<?php
namespace Lavoisier;
namespace Lavoisier\Hydrators;
/**
* @author Olivier LEQUEUX
......
<?php
require_once dirname(__FILE__) . '/../../Lavoisier/IEntries.php';
require_once dirname(__FILE__) . '/../Entries.php';
require_once dirname(__FILE__) . '/../IHydrator.php';
require_once dirname(__FILE__) . '/../Hydrators/EntriesHydrator.php';
namespace Lavoisier\Hydrators;
use \Lavoisier\Hydrators\EntriesHydrator;
use Lavoisier\Hydrators\EntriesHydrator;
class EntriesHydratorTest extends \PHPUnit_Framework_TestCase
......
<?php
require_once dirname(__FILE__) . '/../../Lavoisier/IEntries.php';
require_once dirname(__FILE__) . '/../Entries.php';
require_once dirname(__FILE__) . '/../IHydrator.php';
require_once dirname(__FILE__) . '/../Hydrators/EntriesHydrator.php';
require_once dirname(__FILE__) . '/../../TicketingSystem/Ticket/ArrayFields.php';
require_once dirname(__FILE__) . '/../../TicketingSystem/Ticket/GgusFields.php';
use \Lavoisier\Entries;
use \Lavoisier\Entries\Entries;
class EntriesTest extends \PHPUnit_Framework_TestCase
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment