Skip to content

Commit

Permalink
Add a skipped test for cyclic references
Browse files Browse the repository at this point in the history
  • Loading branch information
stasm committed Oct 9, 2017
1 parent 39a80b7 commit 165a75c
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions tests/resolve_message_reference.rs
Expand Up @@ -42,3 +42,19 @@ fn message_reference_missing() {
let value = ctx.get_message("bar").and_then(|msg| ctx.format(msg, None));
assert_eq!(value, Some("___ Bar".to_string()));
}

#[test]
#[ignore]
fn message_reference_cyclic() {
let mut ctx = MessageContext::new("x-testing");

ctx.add_messages(
"
foo = Foo { bar }
bar = { foo } Bar
",
);

let value = ctx.get_message("foo").and_then(|msg| ctx.format(msg, None));
assert_eq!(value, Some("Foo ___".to_string()));
}

0 comments on commit 165a75c

Please sign in to comment.