handle roster history without steam group

This commit is contained in:
Robin Appelman 2024-02-25 13:44:40 +01:00
commit c81cc2f717
5 changed files with 2460 additions and 10 deletions

File diff suppressed because it is too large Load diff

View file

@ -36,6 +36,7 @@ fn test_parse_team_html(input: &str, name: &str) {
}
#[test_case("team_roster_history_7861.html", "team_roster_history")]
#[test_case("team_roster_history_2133.html", "team_roster_history_no_group")]
fn test_parse_team_roster_history_html(input: &str, name: &str) {
let body = read_to_string(&format!("tests/data/{input}")).unwrap();
let parser = TeamRosterHistoryParser::new();

View file

@ -0,0 +1,33 @@
---
source: tests/snapshot.rs
expression: parsed
---
{
"steam_group": null,
"history": [
{
"name": "elwood",
"steam_id": "76561197961197074",
"joined": "2007-10-04",
"left": "2008-01-14"
},
{
"name": "crumbles",
"steam_id": "76561197963844061",
"joined": "2007-10-04",
"left": "2008-01-14"
},
{
"name": "AO",
"steam_id": "76561197960464501",
"joined": "2007-10-04",
"left": "2008-01-14"
},
{
"name": "Klone",
"steam_id": "76561197961272077",
"joined": "2007-10-04",
"left": "2008-01-14"
}
]
}