Skip to content

Commit

Permalink
test: fix subtitles unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
tymmesyde committed Dec 4, 2024
1 parent 100d280 commit 2938380
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/unit_tests/serde/default_tokens_ext.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,10 @@ impl DefaultTokens for Subtitles {
vec![
Token::Struct {
name: "Subtitles",
len: 2,
len: 3,
},
Token::Str("id"),
Token::Str(""),
Token::Str("lang"),
Token::Str(""),
Token::Str("url"),
Expand Down
5 changes: 4 additions & 1 deletion src/unit_tests/serde/subtitles.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,17 @@ use url::Url;
fn subtitles() {
assert_tokens(
&Subtitles {
id: "id".to_owned(),
lang: "lang".to_owned(),
url: Url::parse("https://url").unwrap(),
},
&[
Token::Struct {
name: "Subtitles",
len: 2,
len: 3,
},
Token::Str("id"),
Token::Str("id"),
Token::Str("lang"),
Token::Str("lang"),
Token::Str("url"),
Expand Down

0 comments on commit 2938380

Please sign in to comment.