diff options
author | Teryk Bellahsene <teryk.bellahsene@sonarsource.com> | 2014-10-31 16:33:15 +0100 |
---|---|---|
committer | Teryk Bellahsene <teryk.bellahsene@sonarsource.com> | 2014-10-31 16:33:30 +0100 |
commit | 605455cb03c5cf67a8c2e4a1d8ba1b7b90f4c63b (patch) | |
tree | 45e2feb4b95629ca362af1c0e1e988085e07380c /sonar-plugin-api | |
parent | 0ffd9d683485c9a179e83ed4a466370c6036d1fe (diff) | |
download | sonarqube-605455cb03c5cf67a8c2e4a1d8ba1b7b90f4c63b.tar.gz sonarqube-605455cb03c5cf67a8c2e4a1d8ba1b7b90f4c63b.zip |
Improve branch code coverage on snapshot related classes
Diffstat (limited to 'sonar-plugin-api')
-rw-r--r-- | sonar-plugin-api/src/main/java/org/sonar/api/utils/DateUtils.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/utils/DateUtils.java b/sonar-plugin-api/src/main/java/org/sonar/api/utils/DateUtils.java index 3985ddafeb9..a36ce0a44ea 100644 --- a/sonar-plugin-api/src/main/java/org/sonar/api/utils/DateUtils.java +++ b/sonar-plugin-api/src/main/java/org/sonar/api/utils/DateUtils.java @@ -130,6 +130,10 @@ public final class DateUtils { return datetime; } + public static Date addDays(Date date, int numberOfDays) { + return org.apache.commons.lang.time.DateUtils.addDays(date, numberOfDays); + } + static class ThreadSafeDateFormat extends DateFormat { private final String format; private final ThreadLocal<Reference<DateFormat>> cache = new ThreadLocal<Reference<DateFormat>>() { |