We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
@@ 87-108 (lines=22) @@ | ||
84 | $this->errorHandler->handleErrors($executionResult, true); |
|
85 | } |
|
86 | ||
87 | public function testMaskErrorWithWrappedUserErrorAndThrowExceptionSetToTrue() |
|
88 | { |
|
89 | $executionResult = new ExecutionResult( |
|
90 | null, |
|
91 | [ |
|
92 | new Error('Error with wrapped user error', null, new UserError('My User Error')), |
|
93 | ] |
|
94 | ); |
|
95 | ||
96 | $this->errorHandler->handleErrors($executionResult, true); |
|
97 | ||
98 | $expected = [ |
|
99 | 'data' => null, |
|
100 | 'errors' => [ |
|
101 | [ |
|
102 | 'message' => 'Error with wrapped user error', |
|
103 | ], |
|
104 | ], |
|
105 | ]; |
|
106 | ||
107 | $this->assertEquals($expected, $executionResult->toArray()); |
|
108 | } |
|
109 | ||
110 | public function testMaskErrorWithoutWrappedExceptionAndThrowExceptionSetToTrue() |
|
111 | { |
|
@@ 110-131 (lines=22) @@ | ||
107 | $this->assertEquals($expected, $executionResult->toArray()); |
|
108 | } |
|
109 | ||
110 | public function testMaskErrorWithoutWrappedExceptionAndThrowExceptionSetToTrue() |
|
111 | { |
|
112 | $executionResult = new ExecutionResult( |
|
113 | null, |
|
114 | [ |
|
115 | new Error('Error without wrapped exception'), |
|
116 | ] |
|
117 | ); |
|
118 | ||
119 | $this->errorHandler->handleErrors($executionResult, true); |
|
120 | ||
121 | $expected = [ |
|
122 | 'data' => null, |
|
123 | 'errors' => [ |
|
124 | [ |
|
125 | 'message' => 'Error without wrapped exception', |
|
126 | ], |
|
127 | ], |
|
128 | ]; |
|
129 | ||
130 | $this->assertEquals($expected, $executionResult->toArray()); |
|
131 | } |
|
132 | ||
133 | public function testMaskErrorOverrideErrorHandle() |
|
134 | { |