Skip to content

Commit

Permalink
Apply clippy suggestions to test code
Browse files Browse the repository at this point in the history
  • Loading branch information
Ortham committed Jan 14, 2025
1 parent e844207 commit 2e86b63
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/plugin.rs
Original file line number Diff line number Diff line change
Expand Up @@ -873,7 +873,7 @@ mod tests {

#[test]
fn game_id_should_return_the_plugins_associated_game_id() {
let plugin = Plugin::new(GameId::Morrowind, &Path::new("Data/Blank.esm"));
let plugin = Plugin::new(GameId::Morrowind, Path::new("Data/Blank.esm"));

assert_eq!(GameId::Morrowind, plugin.game_id());
}
Expand Down Expand Up @@ -1237,7 +1237,7 @@ mod tests {

#[test]
fn game_id_should_return_the_plugins_associated_game_id() {
let plugin = Plugin::new(GameId::Skyrim, &Path::new("Data/Blank.esm"));
let plugin = Plugin::new(GameId::Skyrim, Path::new("Data/Blank.esm"));

assert_eq!(GameId::Skyrim, plugin.game_id());
}
Expand Down Expand Up @@ -2659,7 +2659,7 @@ mod tests {
#[test]
fn hashed_masters_for_starfield_should_count_mod_indexes_separately_for_different_plugin_scales(
) {
let masters: Vec<_> = (0..7).into_iter().map(|i| i.to_string()).collect();
let masters: Vec<_> = (0..7).map(|i| i.to_string()).collect();
let metadata = &[
PluginMetadata {
filename: masters[0].clone(),
Expand Down
4 changes: 2 additions & 2 deletions src/subrecord.rs
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ mod tests {
mod morrowind {
use super::super::*;

const TES3_DATA_SUBRECORD: &'static [u8] = &[
const TES3_DATA_SUBRECORD: &[u8] = &[
0x44, 0x41, 0x54, 0x41, 0x08, 0x00, 0x00, 0x00, 0x6D, 0x63, 0x61, 0x72, 0x6F, 0x66,
0x61, 0x6E,
];
Expand Down Expand Up @@ -206,7 +206,7 @@ mod tests {
mod nonmorrowind {
use super::super::*;

const TES4_CNAM_SUBRECORD: &'static [u8] = &[
const TES4_CNAM_SUBRECORD: &[u8] = &[
0x43, 0x4E, 0x41, 0x4D, 0x0A, 0x00, 0x6D, 0x63, 0x61, 0x72, 0x6F, 0x66, 0x61, 0x6E,
0x6F, 0x00,
];
Expand Down

0 comments on commit 2e86b63

Please sign in to comment.