Project

General

Profile

« Previous | Next » 

Revision f1a25720

Added by Katja Luther over 6 years ago

  • ID f1a25720755daa96e8838a617a660dfced7b9f31
  • Parent 23e50194

first implementation for change from joda time to java8 time

View differences:

cdmlib-persistence/src/test/java/eu/etaxonomy/cdm/persistence/dao/jdbc/validation/EntityValidationCrudJdbcImplTest.java
14 14
import static org.junit.Assert.assertTrue;
15 15

  
16 16
import java.io.FileNotFoundException;
17
import java.time.ZoneId;
18
import java.time.ZonedDateTime;
17 19
import java.util.ArrayList;
18 20
import java.util.Collections;
19 21
import java.util.Comparator;
......
28 30

  
29 31
import org.hibernate.validator.HibernateValidator;
30 32
import org.hibernate.validator.HibernateValidatorConfiguration;
31
import org.joda.time.DateTime;
32 33
import org.junit.Before;
33 34
import org.junit.Ignore;
34 35
import org.junit.Test;
......
150 151

  
151 152
        // All same as in @DataSet:
152 153

  
153
        DateTime created = new DateTime(2014, 1, 1, 0, 0);
154
        ZonedDateTime created = ZonedDateTime.of(2014, 1, 1, 0, 0, 0, 0, ZoneId.systemDefault());
154 155

  
155 156
        Employee emp = new Employee();
156 157
        emp.setId(100);
......
202 203

  
203 204
        // All identical to @DataSet:
204 205

  
205
        DateTime created = new DateTime(2014, 1, 1, 0, 0);
206
        ZonedDateTime created = ZonedDateTime.of(2014, 1, 1, 0, 0, 0, 0, ZoneId.systemDefault());
206 207

  
207 208
        Employee emp = new Employee();
208 209
        emp.setId(100);
......
248 249
    // having 1 entityconstraintviolation)
249 250
    public void testSameErrorOtherEntity() {
250 251

  
251
        DateTime created = new DateTime(2014, 1, 1, 0, 0);
252
        ZonedDateTime created = ZonedDateTime.of(2014, 1, 1, 0, 0, 0, 0, ZoneId.systemDefault());
252 253

  
253 254
        // Not in @DataSet
254 255
        Employee emp = new Employee();
......
293 294
    // having 1 entityconstraintviolation)
294 295
    public void testOneOldOneNewError() {
295 296

  
296
        DateTime created = new DateTime(2014, 1, 1, 0, 0);
297
        ZonedDateTime created = ZonedDateTime.of(2014, 1, 1, 0, 0, 0, 0, ZoneId.systemDefault());
297 298

  
298 299
        // Same entity as in @DataSet
299 300
        Employee emp = new Employee();
......
353 354
    // increased.
354 355
    public void testAllErrorsSolved() {
355 356

  
356
        DateTime created = new DateTime(2014, 1, 1, 0, 0);
357
        ZonedDateTime created = ZonedDateTime.of(2014, 1, 1, 0, 0, 0, 0, ZoneId.systemDefault());
357 358

  
358 359
        Employee emp = new Employee();
359 360
        emp.setId(100);

Also available in: Unified diff