Uploaded image for project: 'Apache Avro'
  1. Apache Avro
  2. AVRO-3766

[Rust] Print friendlier errors when test cases fail

    XMLWordPrintableJSON

Details

    Description

      https://bluxte.net/musings/2023/01/08/improving_failure_messages_rust_tests/

       

      The idea is to use  #[track_caller] attribute on a method that panics immediately.

      This way the "useless" frames from the unwinding are not printed.

      An extra benefit is the removal of calls to Result::unwrap() in the tests.

      Attachments

        Issue Links

          Activity

            People

              mgrigorov Martin Tzvetanov Grigorov
              mgrigorov Martin Tzvetanov Grigorov
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m