@Test
public void testPrecisionTooLarge() throws ParseException {

  FormatOptions options = FormatOptions.parse("%.999999x", 1, 8, false);
  assertThat(options).hasWidth(-1);
  assertThat(options).hasPrecision(999999);
  assertThat(options).hasNoFlags();
  try {
    FormatOptions.parse("%.1000000x", 2, 9, false);
    fail("expected ParseException");
  } catch (ParseException expected) {
  }
}