@@ -798,3 +798,45 @@ fn test_unloaded() {
798798 insta:: assert_snapshot!( "json-pretty-unloaded" , json_out) ;
799799 assert_eq ! ( stderr, "" ) ;
800800}
801+
802+ #[ test]
803+ fn test_macos_inlines_json_pretty ( ) {
804+ // For a while this didn't parse right
805+ let bin = env ! ( "CARGO_BIN_EXE_minidump-stackwalk" ) ;
806+ let output = Command :: new ( bin)
807+ . arg ( "--json" )
808+ . arg ( "--pretty" )
809+ . arg ( "--symbols-path=../testdata/symbols/" )
810+ . arg ( "../testdata/pipeline-inlines-macos-segv.dmp" )
811+ . stdout ( Stdio :: piped ( ) )
812+ . stderr ( Stdio :: piped ( ) )
813+ . output ( )
814+ . unwrap ( ) ;
815+
816+ let stdout = String :: from_utf8 ( output. stdout ) . unwrap ( ) ;
817+ let stderr = String :: from_utf8 ( output. stderr ) . unwrap ( ) ;
818+
819+ assert ! ( output. status. success( ) ) ;
820+ insta:: assert_snapshot!( stdout) ;
821+ assert_eq ! ( stderr, "" ) ;
822+ }
823+
824+ #[ test]
825+ fn test_macos_inlines_human ( ) {
826+ let bin = env ! ( "CARGO_BIN_EXE_minidump-stackwalk" ) ;
827+ let output = Command :: new ( bin)
828+ . arg ( "--human" )
829+ . arg ( "--symbols-path=../testdata/symbols/" )
830+ . arg ( "../testdata/pipeline-inlines-macos-segv.dmp" )
831+ . stdout ( Stdio :: piped ( ) )
832+ . stderr ( Stdio :: piped ( ) )
833+ . output ( )
834+ . unwrap ( ) ;
835+
836+ let stdout = String :: from_utf8 ( output. stdout ) . unwrap ( ) ;
837+ let stderr = String :: from_utf8 ( output. stderr ) . unwrap ( ) ;
838+
839+ assert ! ( output. status. success( ) ) ;
840+ insta:: assert_snapshot!( stdout) ;
841+ assert_eq ! ( stderr, "" ) ;
842+ }
0 commit comments