refactor: add needless_raw_strings clippy correctness lint (#931)

This commit is contained in:
Alex Yusiuk
2025-08-25 07:17:25 -04:00
committed by GitHub
parent ff2c968052
commit 6fddcaae38
7 changed files with 22 additions and 5 deletions
+1
View File
@@ -104,6 +104,7 @@ as_underscore = "warn"
large_stack_frames = "warn"
mem_forget = "warn"
mixed_read_write_in_expression = "warn"
needless_raw_strings = "warn"
# == Style, readability == #
semicolon_outside_block = "warn" # With semicolon-outside-block-ignore-multiline = true
+4
View File
@@ -390,6 +390,10 @@ pub(crate) fn compress_8bpp_plane(
}
#[cfg(test)]
#[expect(
clippy::needless_raw_strings,
reason = "the lint is disable to not interfere with expect! macro"
)]
mod tests {
use expect_test::expect;
@@ -166,6 +166,10 @@ impl Encode for BitmapStream<'_> {
#[cfg(test)]
#[cfg(feature = "alloc")]
#[expect(
clippy::needless_raw_strings,
reason = "the lint is disable to not interfere with expect! macro"
)]
mod tests {
use expect_test::{expect, Expect};
+4
View File
@@ -555,6 +555,10 @@ pub(crate) mod legacy {
}
#[cfg(test)]
#[expect(
clippy::needless_raw_strings,
reason = "the lint is disable to not interfere with expect! macro"
)]
mod tests {
use expect_test::expect;
@@ -2,6 +2,10 @@ mod gcc;
mod gfx;
mod input;
mod mcs;
#[expect(
clippy::needless_raw_strings,
reason = "the lint is disable to not interfere with expect! macro"
)]
mod pointer;
mod rdp;
mod rfx;
@@ -1,7 +1,7 @@
use expect_test::expect;
use ironrdp_rdpfile::ParseResult;
const RDP_FILE_SAMPLE: &str = r#"remoteapplicationmode:i:0
const RDP_FILE_SAMPLE: &str = "remoteapplicationmode:i:0
server port:i:3389
promptcredentialonce:i:1
full address:s:192.168.56.101
@@ -11,11 +11,11 @@ alternate full address:s:some.alternateaddress.ninja
username:s:David
ClearTextPassword:s:Devolutions123!
MalformedLine:s
UnknownType:z:10293"#;
UnknownType:z:10293";
const RDP_FILE_SAMPLE_2: &str = r#"remoteapplicationmode:i:50
const RDP_FILE_SAMPLE_2: &str = "remoteapplicationmode:i:50
server port:i:4000
full address:s:192.168.56.2"#;
full address:s:192.168.56.2";
#[test]
fn parse_file() {
+1 -1
View File
@@ -3,7 +3,7 @@ use core::fmt;
use crate::prelude::*;
const COV_IGNORE_REGEX: &str =
r#"(crates/ironrdp-(session|.+generators|.+glutin.+|replay|client|fuzzing|tokio|web|futures|tls)|xtask|testsuite)"#;
"(crates/ironrdp-(session|.+generators|.+glutin.+|replay|client|fuzzing|tokio|web|futures|tls)|xtask|testsuite)";
pub fn install(sh: &Shell) -> anyhow::Result<()> {
let _s = Section::new("COV-INSTALL");