1
Fork 0
mirror of https://github.com/redstrate/Physis.git synced 2025-05-09 11:57:46 +00:00

Fix more test breakages

This commit is contained in:
Joshua Goins 2025-05-05 17:56:14 -04:00
parent 62b13f557a
commit f822aabb94
2 changed files with 4 additions and 6 deletions

View file

@ -147,7 +147,7 @@ impl GameData {
///
/// # Example
///
/// ```should_panic
/// ```
/// # use physis::common::Platform;
/// use physis::gamedata::GameData;
/// # let mut game = GameData::from_existing(Platform::Win32, "SquareEnix/Final Fantasy XIV - A Realm Reborn/game");
@ -203,7 +203,7 @@ impl GameData {
/// Parses a path structure and spits out the corresponding category and repository.
fn parse_repository_category(&self, path: &str) -> Option<(&Repository, Category)> {
if self.repositories.is_empty() {
return None
return None;
}
let tokens = path.split_once('/')?;

View file

@ -18,8 +18,7 @@ fn test_gamedata_extract() {
let mut game_data = physis::gamedata::GameData::from_existing(
Platform::Win32,
format!("{}/game", game_dir).as_str(),
)
.unwrap();
);
assert!(game_data.extract("exd/root.exl").is_some());
}
@ -37,8 +36,7 @@ fn test_item_read() {
let mut game_data = physis::gamedata::GameData::from_existing(
Platform::Win32,
format!("{}/game", game_dir).as_str(),
)
.unwrap();
);
let exh = game_data.read_excel_sheet_header("Item").unwrap();
let exd = game_data