Stebalien / term

A Rust library for terminfo parsing and terminal colors.
https://stebalien.github.io/doc/term/term/
Apache License 2.0
178 stars 49 forks source link

Make tests pass on Rust 1.53 #109

Closed syvb closed 3 years ago

syvb commented 3 years ago

Since all warnings are denyed when cfg(test), new warnings in rustc make tests fail. A new warning was added to rustc, so they fail with warnings like this:

error: panic message is not a string literal
   --> src/terminfo/parm.rs:682:34
    |
682 |             assert!(res.is_ok(), res.err().unwrap());
    |                                  ^^^^^^^^^^^^^^^^^^
    |
    = note: this is no longer accepted in Rust 2021
help: add a "{}" format string to Display the message
    |
682 |             assert!(res.is_ok(), "{}", res.err().unwrap());
    |                                  ^^^^^

This fixes that by correcting the warnings, and tests now pass.

Stebalien commented 3 years ago

Thanks!