@Test public void testNonEmbeddedStrangeFieldName() throws JSONObjectException, IOException { DefaultArgsConverter ac = new DefaultArgsConverter(); ac.setFieldName(STRANGE_SEQ); CustomField[] custFields = new CustomField[] { customField(STRANGE_SEQ, STRANGE_SEQ) }; assertThat(makeMap(custFields), is(mapFrom(formatArgs(ac, custFields)).get(STRANGE_SEQ))); }
@Test public void testNonEmbeddedSingleArg() throws JSONObjectException, IOException { DefaultArgsConverter ac = new DefaultArgsConverter(); ac.setFieldName(PREFIX); CustomField[] custFields = new CustomField[] { customField(SOME_KEY, SOME_VALUE) }; assertThat(makeMap(custFields), is(mapFrom(formatArgs(ac, custFields)).get(PREFIX))); }
@Test public void testNonEmbeddedStrangeValue() throws JSONObjectException, IOException { DefaultArgsConverter ac = new DefaultArgsConverter(); ac.setFieldName(PREFIX); CustomField[] custFields = new CustomField[] { customField(SOME_KEY, STRANGE_SEQ) }; assertThat(makeMap(custFields), is(mapFrom(formatArgs(ac, custFields)).get(PREFIX))); }
@Test public void testNonEmbeddedStrangeKey() throws JSONObjectException, IOException { DefaultArgsConverter ac = new DefaultArgsConverter(); ac.setFieldName(PREFIX); CustomField[] custFields = new CustomField[] { customField(STRANGE_SEQ, STRANGE_SEQ) }; assertThat(makeMap(custFields), is(mapFrom(formatArgs(ac, custFields)).get(PREFIX))); }
@Test public void testEmbeddedStrangeValue() throws JSONObjectException, IOException { DefaultArgsConverter ac = new DefaultArgsConverter(); CustomField[] custFields = new CustomField[] { customField(SOME_KEY, STRANGE_SEQ) }; assertThat(makeMap(custFields), is(mapFrom(formatArgs(ac, custFields)))); }
@Test public void testEmbeddedSingleArg() throws JSONObjectException, IOException { DefaultArgsConverter ac = new DefaultArgsConverter(); CustomField[] custFields = new CustomField[] { customField(SOME_KEY, SOME_VALUE) }; assertThat(makeMap(custFields), is(mapFrom(formatArgs(ac, custFields)))); }
@Test public void testEmbeddedStrangeKey() throws JSONObjectException, IOException { DefaultArgsConverter ac = new DefaultArgsConverter(); CustomField[] custFields = new CustomField[] { customField(STRANGE_SEQ, STRANGE_SEQ) }; assertThat(makeMap(custFields), is(mapFrom(formatArgs(ac, custFields)))); }