Skip to content

Commit

Permalink
test for 2759
Browse files Browse the repository at this point in the history
  • Loading branch information
kennykerr committed Jan 5, 2024
1 parent 623e811 commit 1410e73
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions crates/tests/implement/tests/vector.rs
Original file line number Diff line number Diff line change
Expand Up @@ -275,3 +275,18 @@ fn test() -> Result<()> {

Ok(())
}

// Test for https://github.com/microsoft/windows-rs/issues/2759
#[test]
fn test_2759() -> Result<()> {
let v: IVector<IStringable> = Vector::new(vec![]).into();
let uri = Uri::CreateUri(h!("https://github.com/"))?;
v.Append(&uri)?;
let uri = Uri::CreateUri(h!("https://microsoft.com/"))?;
v.Append(&uri)?;

assert_eq!(&v.GetAt(0)?.ToString()?, h!("https://github.com/"));
assert_eq!(&v.GetAt(1)?.ToString()?, h!("https://microsoft.com/"));

Ok(())
}

0 comments on commit 1410e73

Please sign in to comment.