| @@ 84-96 (lines=13) @@ | ||
| 81 | /** |
|
| 82 | * @test |
|
| 83 | */ |
|
| 84 | public function shouldParseObjectWrapper() |
|
| 85 | { |
|
| 86 | //given |
|
| 87 | $parameter = 'wrapper $user @className=\Mocks\MockUserWrapper'; |
|
| 88 | $parser = new ParameterParser($parameter); |
|
| 89 | ||
| 90 | //when |
|
| 91 | $parser->parse(); |
|
| 92 | ||
| 93 | //then |
|
| 94 | $this->assertEquals('user', $parser->getName()); |
|
| 95 | $this->assertEquals('MocksMockUserWrapper', $parser->getType()); |
|
| 96 | } |
|
| 97 | ||
| 98 | /** |
|
| 99 | * @test |
|
| @@ 101-113 (lines=13) @@ | ||
| 98 | /** |
|
| 99 | * @test |
|
| 100 | */ |
|
| 101 | public function shouldParseObjectWrapperArray() |
|
| 102 | { |
|
| 103 | //given |
|
| 104 | $parameter = 'wrapper[] $users @className=\Mocks\MockUserWrapper'; |
|
| 105 | $parser = new ParameterParser($parameter); |
|
| 106 | ||
| 107 | //when |
|
| 108 | $parser->parse(); |
|
| 109 | ||
| 110 | //then |
|
| 111 | $this->assertEquals('users', $parser->getName()); |
|
| 112 | $this->assertEquals('MocksMockUserWrapper', $parser->getType()); |
|
| 113 | } |
|
| 114 | ||
| 115 | /** |
|
| 116 | * @test |
|