Skip to content

Commit 1780a05

Browse files
update readme, closes #6
1 parent dd43470 commit 1780a05

File tree

3 files changed

+8
-1
lines changed

3 files changed

+8
-1
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,4 +131,4 @@ these are not operated on each object in the stream
131131
<li>DateTimeFormatter - parse String to LocalDate|LocalTime|LocalDateTime and format LocalDate|LocalTime|LocalDateTime to String</li>
132132
</ol>
133133

134-
<h4>End-of-the-file</h4>
134+
<h4>End of the file</h4>

build.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ plugins {
22
id 'org.springframework.boot' version '2.2.6.RELEASE'
33
id 'io.spring.dependency-management' version '1.0.9.RELEASE'
44
id 'java'
5+
id 'jacoco'
56
}
67

78
group = 'com.learn'

src/test/java/com/learn/java8/dateTime/LocalDateTimeParseFormatDateTimeFormatterTest.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,12 @@ void parse() {
4444
DateTimeFormatter dateTimeFormatter2 = DateTimeFormatter.ofPattern("yyyy|MM|dd'T'HH||mm||ss");
4545
LocalDateTime localDateTime5 = LocalDateTime.parse(dateTime5, dateTimeFormatter2);
4646
log.info("localTime " + localDateTime5);
47+
48+
String dateTime6 = "2020|05|12abc21||05||16";
49+
log.info("dateTime " + dateTime6);
50+
DateTimeFormatter dateTimeFormatter3 = DateTimeFormatter.ofPattern("yyyy|MM|dd'abc'HH||mm||ss");
51+
LocalDateTime localDateTime6 = LocalDateTime.parse(dateTime6, dateTimeFormatter3);
52+
log.info("localTime " + localDateTime6);
4753
}
4854

4955
@Test

0 commit comments

Comments
 (0)