public function testGet()
 {
     $expectedConfiguration = $this->faker->name;
     $loader = $this->getMockBuilder('\\ConfigurationFactory\\Loaders\\Php')->setMethods(['getConfigurationKey', 'loadByKey'])->getMock();
     $loader->expects($this->once())->method('getConfigurationKey')->willReturn($this->faker->name);
     $loader->expects($this->once())->method('loadByKey')->willReturn($expectedConfiguration);
     $factory = new ConfigurationFactory();
     $factory->setNamespace($this->faker->name);
     $factory->setLoader($loader);
     $this->assertEquals($expectedConfiguration, $factory->get($this->faker->name));
 }
<?php

use ConfigurationFactory\Factory;
use ConfigurationFactory\Loaders\Php as Loader;
use NwWebsite\Di;
$di = Di::getInstance();
$loader = new Loader();
$factory = new Factory();
$factory->setNamespace($di->rootPath . DIRECTORY_SEPARATOR . 'config');
$factory->setLoader($loader);
return $factory;