@@ -302,7 +302,7 @@ describe("Tests exception handling ", function () {
302
302
errMsg = e . toString ( ) ;
303
303
}
304
304
expect ( exceptionCaught ) . toBe ( true ) ;
305
- expect ( errMsg ) . toBe ( "Error: Unknown error. Cannot get error message. " ) ;
305
+ expect ( errMsg ) . toBe ( "Error: com.tns.tests.ExceptionHandlingTest$BadException " ) ;
306
306
} ) ;
307
307
308
308
it ( "should successfully catch syntax errors" , function ( ) {
@@ -320,18 +320,18 @@ describe("Tests exception handling ", function () {
320
320
expect ( errMsg ) . toContain ( "File: (file:///data/data/com.tns.testapplication/files/app/tests/syntaxErrors.js:3:4)" ) ;
321
321
} ) ;
322
322
323
- // run this test only for API level bigger than 25 as we have handling there
324
- if ( android . os . Build . VERSION . SDK_INT > 25 && android . os . Build . CPU_ABI != "x86" && android . os . Build . CPU_ABI != "x86_64" ) {
325
- it ( "Should handle SIGABRT and throw a NativeScript exception when incorrectly calling JNI methods" , function ( ) {
326
- let myClassInstance = new com . tns . tests . MyTestBaseClass3 ( ) ;
327
- // public void callMeWithAString(java.lang.String[] stringArr, Runnable arbitraryInterface)
328
- try {
329
- myClassInstance . callMeWithAString ( "stringVal" , new java . lang . Runnable ( { run : ( ) => { } } ) )
330
- } catch ( e ) {
331
- android . util . Log . d ( "~~~~~" , "~~~~~~~~ " + e . toString ( ) ) ;
332
-
333
- expect ( e . toString ( ) ) . toContain ( "SIGABRT" ) ;
334
- }
335
- } ) ;
336
- }
323
+ // run this test only for API level bigger than 25 as we have handling there
324
+ if ( android . os . Build . VERSION . SDK_INT > 25 && android . os . Build . CPU_ABI != "x86" && android . os . Build . CPU_ABI != "x86_64" ) {
325
+ it ( "Should handle SIGABRT and throw a NativeScript exception when incorrectly calling JNI methods" , function ( ) {
326
+ let myClassInstance = new com . tns . tests . MyTestBaseClass3 ( ) ;
327
+ // public void callMeWithAString(java.lang.String[] stringArr, Runnable arbitraryInterface)
328
+ try {
329
+ myClassInstance . callMeWithAString ( "stringVal" , new java . lang . Runnable ( { run : ( ) => { } } ) )
330
+ } catch ( e ) {
331
+ android . util . Log . d ( "~~~~~" , "~~~~~~~~ " + e . toString ( ) ) ;
332
+
333
+ expect ( e . toString ( ) ) . toContain ( "SIGABRT" ) ;
334
+ }
335
+ } ) ;
336
+ }
337
337
} ) ;
0 commit comments