fix: use fixed testfiles location

This commit is contained in:
ThetaDev 2023-03-25 23:18:49 +01:00
parent 3a2e4c8abe
commit 7bcff13eb8
20 changed files with 80 additions and 62 deletions

View file

@ -85,12 +85,12 @@ mod tests {
use rstest::rstest;
use super::*;
use crate::{param::Language, serializer::MapResult};
use crate::{param::Language, serializer::MapResult, util::tests::TESTFILES};
#[rstest]
#[case::default("default")]
fn map_music_new_albums(#[case] name: &str) {
let json_path = path!("testfiles" / "music_new" / format!("albums_{name}.json"));
let json_path = path!(*TESTFILES / "music_new" / format!("albums_{name}.json"));
let json_file = File::open(json_path).unwrap();
let new_albums: response::MusicNew =
@ -109,7 +109,7 @@ mod tests {
#[rstest]
#[case::default("default")]
fn map_music_new_videos(#[case] name: &str) {
let json_path = path!("testfiles" / "music_new" / format!("videos_{name}.json"));
let json_path = path!(*TESTFILES / "music_new" / format!("videos_{name}.json"));
let json_file = File::open(json_path).unwrap();
let new_albums: response::MusicNew =