Init RTD v2 config

This commit is contained in:
borislavsabev
2023-09-20 15:49:24 +03:00
parent d9439e3650
commit b8aa050a73
43 changed files with 63 additions and 47 deletions

View File

@@ -67,5 +67,5 @@ Tests/AdapterTest.php
:language: php
:linenos:
.. _`GitHub`: https://github.com/domnikl/DesignPatternsPHP/tree/main/Structural/Adapter
.. _`GitHub`: https://github.com/DesignPatternsPHP/DesignPatternsPHP/tree/main/Structural/Adapter
.. __: http://en.wikipedia.org/wiki/Adapter_pattern

View File

@@ -64,5 +64,5 @@ Tests/BridgeTest.php
:language: php
:linenos:
.. _`GitHub`: https://github.com/domnikl/DesignPatternsPHP/tree/main/Structural/Bridge
.. _`GitHub`: https://github.com/DesignPatternsPHP/DesignPatternsPHP/tree/main/Structural/Bridge
.. __: http://en.wikipedia.org/wiki/Bridge_pattern

View File

@@ -59,5 +59,5 @@ Tests/CompositeTest.php
:language: php
:linenos:
.. _`GitHub`: https://github.com/domnikl/DesignPatternsPHP/tree/main/Structural/Composite
.. _`GitHub`: https://github.com/DesignPatternsPHP/DesignPatternsPHP/tree/main/Structural/Composite
.. __: http://en.wikipedia.org/wiki/Composite_pattern

View File

@@ -62,5 +62,5 @@ Tests/DataMapperTest.php
:language: php
:linenos:
.. _`GitHub`: https://github.com/domnikl/DesignPatternsPHP/tree/main/Structural/DataMapper
.. _`GitHub`: https://github.com/DesignPatternsPHP/DesignPatternsPHP/tree/main/Structural/DataMapper
.. __: http://en.wikipedia.org/wiki/Data_mapper_pattern

View File

@@ -14,7 +14,7 @@ class DataMapperTest extends TestCase
{
public function testCanMapUserFromStorage()
{
$storage = new StorageAdapter([1 => ['username' => 'domnikl', 'email' => 'liebler.dominik@gmail.com']]);
$storage = new StorageAdapter([1 => ['username' => 'someone', 'email' => 'someone@example.com']]);
$mapper = new UserMapper($storage);
$user = $mapper->findById(1);

View File

@@ -63,5 +63,5 @@ Tests/DecoratorTest.php
:language: php
:linenos:
.. _`GitHub`: https://github.com/domnikl/DesignPatternsPHP/tree/main/Structural/Decorator
.. _`GitHub`: https://github.com/DesignPatternsPHP/DesignPatternsPHP/tree/main/Structural/Decorator
.. __: http://en.wikipedia.org/wiki/Decorator_pattern

View File

@@ -59,5 +59,5 @@ Tests/DependencyInjectionTest.php
:language: php
:linenos:
.. _`GitHub`: https://github.com/domnikl/DesignPatternsPHP/tree/main/Structural/DependencyInjection
.. _`GitHub`: https://github.com/DesignPatternsPHP/DesignPatternsPHP/tree/main/Structural/DependencyInjection
.. __: http://en.wikipedia.org/wiki/Dependency_injection

View File

@@ -12,9 +12,9 @@ class DependencyInjectionTest extends TestCase
{
public function testDependencyInjection()
{
$config = new DatabaseConfiguration('localhost', 3306, 'domnikl', '1234');
$config = new DatabaseConfiguration('localhost', 3306, 'user', '1234');
$connection = new DatabaseConnection($config);
$this->assertSame('domnikl:1234@localhost:3306', $connection->getDsn());
$this->assertSame('user:1234@localhost:3306', $connection->getDsn());
}
}

View File

@@ -62,5 +62,5 @@ Tests/FacadeTest.php
:language: php
:linenos:
.. _`GitHub`: https://github.com/domnikl/DesignPatternsPHP/tree/main/Structural/Facade
.. _`GitHub`: https://github.com/DesignPatternsPHP/DesignPatternsPHP/tree/main/Structural/Facade
.. __: http://en.wikipedia.org/wiki/Facade_pattern

View File

@@ -41,5 +41,5 @@ Tests/FluentInterfaceTest.php
:language: php
:linenos:
.. _`GitHub`: https://github.com/domnikl/DesignPatternsPHP/tree/main/Structural/FluentInterface
.. _`GitHub`: https://github.com/DesignPatternsPHP/DesignPatternsPHP/tree/main/Structural/FluentInterface
.. __: http://en.wikipedia.org/wiki/Fluent_interface

View File

@@ -53,5 +53,5 @@ Tests/FlyweightTest.php
:language: php
:linenos:
.. _`GitHub`: https://github.com/domnikl/DesignPatternsPHP/tree/main/Structural/Flyweight
.. _`GitHub`: https://github.com/DesignPatternsPHP/DesignPatternsPHP/tree/main/Structural/Flyweight
.. __: https://en.wikipedia.org/wiki/Flyweight_pattern

View File

@@ -52,5 +52,5 @@ ProxyTest.php
:language: php
:linenos:
.. _`GitHub`: https://github.com/domnikl/DesignPatternsPHP/tree/main/Structural/Proxy
.. _`GitHub`: https://github.com/DesignPatternsPHP/DesignPatternsPHP/tree/main/Structural/Proxy
.. __: http://en.wikipedia.org/wiki/Proxy_pattern

View File

@@ -42,5 +42,5 @@ Tests/RegistryTest.php
:language: php
:linenos:
.. _`GitHub`: https://github.com/domnikl/DesignPatternsPHP/tree/main/Structural/Registry
.. _`GitHub`: https://github.com/DesignPatternsPHP/DesignPatternsPHP/tree/main/Structural/Registry
.. __: http://en.wikipedia.org/wiki/Service_locator_pattern