/libcore/ojluni/src/test/java/time/tck/java/time/format/ |
D | TCKLocalizedFieldParser.java | 117 ParsePosition ppos = new ParsePosition(pos); in test_parse_textField() local 121 TemporalAccessor parsed = dtf.parseUnresolved(text, ppos); in test_parse_textField() 122 if (ppos.getErrorIndex() != -1) { in test_parse_textField() 123 assertEquals(ppos.getErrorIndex(), expectedPos); in test_parse_textField() 125 assertEquals(ppos.getIndex(), expectedPos, "Incorrect ending parse position"); in test_parse_textField() 150 ParsePosition ppos = new ParsePosition(pos); in test_parse_textLocalDate() local 153 TemporalAccessor parsed = dtf.parseUnresolved(text, ppos); in test_parse_textLocalDate() 154 if (ppos.getErrorIndex() != -1) { in test_parse_textLocalDate() 155 assertEquals(ppos.getErrorIndex(), expectedPos); in test_parse_textLocalDate() 157 assertEquals(ppos.getIndex(), expectedPos, "Incorrect ending parse position"); in test_parse_textLocalDate() [all …]
|
/libcore/ojluni/src/test/java/time/test/java/time/format/ |
D | TestReducedParser.java | 187 ParsePosition ppos = new ParsePosition(pos); in test_parseAllStrict() local 189 … TemporalAccessor parsed = getFormatter0(field, width, baseValue).parseUnresolved(input, ppos); in test_parseAllStrict() 190 if (ppos.getErrorIndex() != -1) { in test_parseAllStrict() 191 assertEquals(ppos.getErrorIndex(), parseLen, "error case parse position"); in test_parseAllStrict() 194 assertEquals(ppos.getIndex(), parseLen, "parse position"); in test_parseAllStrict() 201 ParsePosition ppos = new ParsePosition(pos); in test_parseAllLenient() local 203 … TemporalAccessor parsed = getFormatter0(field, width, baseValue).parseUnresolved(input, ppos); in test_parseAllLenient() 204 if (ppos.getErrorIndex() != -1) { in test_parseAllLenient() 205 assertEquals(ppos.getErrorIndex(), parseLen, "error case parse position"); in test_parseAllLenient() 208 assertEquals(ppos.getIndex(), parseLen, "parse position"); in test_parseAllLenient() [all …]
|
D | TestCharLiteralParser.java | 107 ParsePosition ppos = new ParsePosition(pos); in test_parse_success() local 108 TemporalAccessor parsed = getFormatter(c).parseUnresolved(text, ppos); in test_parse_success() 109 if (ppos.getErrorIndex() != -1) { in test_parse_success() 110 assertEquals(ppos.getIndex(), expectedPos); in test_parse_success() 112 assertEquals(ppos.getIndex(), expectedPos); in test_parse_success() 131 ParsePosition ppos = new ParsePosition(pos); in test_parse_error() local 132 getFormatter(c).parseUnresolved(text, ppos); in test_parse_error()
|
D | TestStringLiteralParser.java | 110 ParsePosition ppos = new ParsePosition(pos); in test_parse_success() local 111 TemporalAccessor parsed = getFormatter(s).parseUnresolved(text, ppos); in test_parse_success() 112 if (ppos.getErrorIndex() != -1) { in test_parse_success() 113 assertEquals(ppos.getIndex(), expectedPos); in test_parse_success() 115 assertEquals(ppos.getIndex(), expectedPos); in test_parse_success() 134 ParsePosition ppos = new ParsePosition(pos); in test_parse_error() local 135 getFormatter(s).parseUnresolved(text, ppos); in test_parse_error()
|
D | TestNumberParser.java | 168 ParsePosition ppos = new ParsePosition(pos); in test_parse_fresh() local 174 TemporalAccessor parsed = dtf.parseUnresolved(text, ppos); in test_parse_fresh() 175 if (ppos.getErrorIndex() != -1) { in test_parse_fresh() 176 assertEquals(ppos.getErrorIndex(), expectedPos); in test_parse_fresh() 179 assertEquals(ppos.getIndex(), expectedPos + subsequentWidth); in test_parse_fresh() 188 ParsePosition ppos = new ParsePosition(pos); in test_parse_textField() local 194 TemporalAccessor parsed = dtf.parseUnresolved(text, ppos); in test_parse_textField() 195 if (ppos.getErrorIndex() != -1) { in test_parse_textField() 196 assertEquals(ppos.getErrorIndex(), expectedPos); in test_parse_textField() 199 assertEquals(ppos.getIndex(), expectedPos + subsequentWidth); in test_parse_textField()
|
D | TestFractionPrinterParser.java | 328 ParsePosition ppos = new ParsePosition(pos); in test_parse_nothing() local 329 … TemporalAccessor parsed = getFormatter(field, min, max, decimalPoint).parseUnresolved(text, ppos); in test_parse_nothing() 330 assertEquals(ppos.getErrorIndex(), expected); in test_parse_nothing()
|
D | TestDateTimeFormatterBuilder.java | 287 ParsePosition ppos = new ParsePosition(0); in test_appendValueReduced_subsequent_parse() local 288 TemporalAccessor parsed = f.parseUnresolved("123", ppos); in test_appendValueReduced_subsequent_parse() 289 assertNotNull(parsed, "Parse failed: " + ppos.toString()); in test_appendValueReduced_subsequent_parse()
|