3 import static org.junit.Assert.*;
7 public class CfbBundleTest {
10 public void testFallbackGet() {
12 { "hello", new Object[] {}, "[hello]" },
13 { "hello", new Object[] {"world"}, "[hello][world]"},
14 { null, new Object[] {}, "[null]" },
16 "the.quick.brown.fox",
17 new Object[] {"jumps.over", Integer.valueOf(1), "lazy", "dog"},
18 "[the.quick.brown.fox][jumps.over][1][lazy][dog]"
22 CfbBundleMock bundle = new CfbBundleMock();
24 for (Object[] datum : data) {
25 String key = (String)datum[0];
26 Object[] params = (Object[])datum[1];
27 String expected = (String)datum[2];
28 String actual = bundle.fallbackGet(key, params);
29 assertEquals(expected, actual);