Skip to content

Commit

Permalink
add test
Browse files Browse the repository at this point in the history
  • Loading branch information
samuelcolvin committed Mar 28, 2024
1 parent 4d77bb8 commit 85c6285
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tests/python.rs
Expand Up @@ -257,6 +257,16 @@ fn test_cache_into() {
})
}

#[test]
fn test_use_tape() {
let json = r#" "foo\nbar" "#;
Python::with_gil(|py| {
cache_clear(py);
let obj = python_parse(py, json.as_bytes(), false, StringCacheMode::None, false).unwrap();
assert_eq!(obj.to_string(), "foo\nbar");
})
}

#[test]
fn test_unicode() {
let json = r#"{"💩": "£"}"#;
Expand Down

0 comments on commit 85c6285

Please sign in to comment.