File tree 1 file changed +4
-4
lines changed
packages/functions-compat/src
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 15
15
* limitations under the License.
16
16
*/
17
17
import { expect } from 'chai' ;
18
- import { FunctionsErrorCode } from '@firebase/functions' ;
18
+ import { FunctionsError , FunctionsErrorCode } from '@firebase/functions' ;
19
19
import { createTestService } from '../test/utils' ;
20
20
import firebase , { FirebaseApp } from '@firebase/app-compat' ;
21
21
@@ -35,9 +35,9 @@ async function expectError(
35
35
await promise ;
36
36
} catch ( e ) {
37
37
failed = true ;
38
- expect ( e . code ) . to . equal ( code ) ;
39
- expect ( e . message ) . to . equal ( message ) ;
40
- expect ( e . details ) . to . deep . equal ( details ) ;
38
+ expect ( ( e as FunctionsError ) . code ) . to . equal ( code ) ;
39
+ expect ( ( e as FunctionsError ) . message ) . to . equal ( message ) ;
40
+ expect ( ( e as FunctionsError ) . details ) . to . deep . equal ( details ) ;
41
41
}
42
42
if ( ! failed ) {
43
43
expect ( false , 'Promise should have failed.' ) . to . be . true ;
You can’t perform that action at this time.
0 commit comments