@@ 58-64 (lines=7) @@ | ||
55 | * @expectedException \InvalidArgumentException |
|
56 | * @expectedExceptionMessage Doctrine ORM Connection named "default" does not exist. |
|
57 | */ |
|
58 | public function testGetUnknownConnection() |
|
59 | { |
|
60 | $container = $this->getMockBuilder('Symfony\Component\DependencyInjection\ContainerInterface')->getMock(); |
|
61 | $registry = new Registry($container, [], [], 'default', 'default'); |
|
62 | ||
63 | $registry->getConnection('default'); |
|
64 | } |
|
65 | ||
66 | public function testGetConnectionNames() |
|
67 | { |
|
@@ 106-112 (lines=7) @@ | ||
103 | * @expectedException \InvalidArgumentException |
|
104 | * @expectedExceptionMessage Doctrine ORM Manager named "default" does not exist. |
|
105 | */ |
|
106 | public function testGetUnknownEntityManager() |
|
107 | { |
|
108 | $container = $this->getMockBuilder('Symfony\Component\DependencyInjection\ContainerInterface')->getMock(); |
|
109 | $registry = new Registry($container, [], [], 'default', 'default'); |
|
110 | ||
111 | $registry->getManager('default'); |
|
112 | } |
|
113 | ||
114 | /** |
|
115 | * @expectedException \InvalidArgumentException |
|
@@ 118-124 (lines=7) @@ | ||
115 | * @expectedException \InvalidArgumentException |
|
116 | * @expectedExceptionMessage Doctrine ORM Manager named "default" does not exist. |
|
117 | */ |
|
118 | public function testResetUnknownEntityManager() |
|
119 | { |
|
120 | $container = $this->getMockBuilder('Symfony\Component\DependencyInjection\ContainerInterface')->getMock(); |
|
121 | $registry = new Registry($container, [], [], 'default', 'default'); |
|
122 | ||
123 | $registry->resetManager('default'); |
|
124 | } |
|
125 | ||
126 | public function testReset() |
|
127 | { |