Pārlūkot izejas kodu

[frontend] Have jest tests fail for unhandled promise rejections

Johan Ahlen 5 gadi atpakaļ
vecāks
revīzija
0342c875b4
1 mainītis faili ar 4 papildinājumiem un 0 dzēšanām
  1. 4 0
      desktop/core/src/desktop/js/jest/jest.init.js

+ 4 - 0
desktop/core/src/desktop/js/jest/jest.init.js

@@ -120,3 +120,7 @@ axios.interceptors.request.use(config => {
   console.trace();
   return config;
 });
+
+process.on('unhandledRejection', err => {
+  fail(err);
+});