Skip to content

Commit

Permalink
1. Added the Symfony2 class loader to implement PSR-0 autoloading.
Browse files Browse the repository at this point in the history
Configured PHPUnit config file.
Added an empty test.
  • Loading branch information
odino committed Nov 15, 2011
1 parent a8547f0 commit a3a15f3
Show file tree
Hide file tree
Showing 5 changed files with 70 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
@@ -0,0 +1,3 @@
[submodule "src/Symfony/Component/ClassLoader"]
path = src/Symfony/Component/ClassLoader
url = git://github.com/symfony/ClassLoader.git
13 changes: 13 additions & 0 deletions autoload.php
@@ -0,0 +1,13 @@
<?php

require_once __DIR__.'/src/Symfony/Component/ClassLoader/UniversalClassLoader.php';

use Symfony\Component\ClassLoader\UniversalClassLoader;

$loader = new UniversalClassLoader();
$loader->registerNamespaces(array(
'Symfony' => array(__DIR__.'/src', __DIR__.'/symfony/src'),
'Osidays' => __DIR__.'/src/',
));

$loader->register();
27 changes: 27 additions & 0 deletions phpunit.xml.dist
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>

<phpunit backupGlobals="true"
bootstrap="autoload.php"
backupStaticAttributes="false"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
forceCoversAnnotation="false"
mapTestClassNameToCoveredClassName="false"
processIsolation="false"
stopOnError="false"
stopOnFailure="false"
stopOnIncomplete="false"
stopOnSkipped="false"
syntaxCheck="false"
testSuiteLoaderClass="PHPUnit_Runner_StandardTestSuiteLoader"
strict="false"
verbose="false">

<testsuites>
<testsuite>
<directory >tests</directory>
</testsuite>
</testsuites>
</phpunit>
1 change: 1 addition & 0 deletions src/Symfony/Component/ClassLoader
Submodule ClassLoader added at 5cd07e
26 changes: 26 additions & 0 deletions tests/DijkstraTest.php
@@ -0,0 +1,26 @@
<?php

/*
* This file is part of the Orient package.
*
* (c) Alessandro Nadalin <alessandro.nadalin@gmail.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/

/**
* Class DijkstraTest
*
* @package Osidays
* @subpackage Tests
* @author Alessandro Nadalin <alessandro.nadalin@gmail.com>
*/

use Osidays\Algorithm\ShortestPath\Dijkstra;

class DijkstraTest extends PHPUnit_Framework_TestCase
{

}

0 comments on commit a3a15f3

Please sign in to comment.