Skip to content

Commit

Permalink
Move test to Browser
Browse files Browse the repository at this point in the history
  • Loading branch information
foal committed Dec 7, 2020
1 parent 98fab84 commit 1237aa9
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -228,18 +228,18 @@ public void test_now_ZoneId_nullZoneId() {
}

@Test
public void test_now_ZoneId() {
public void disabled_test_now_ZoneId() {
ZoneId zone = ZoneId.of("UTC+01:02:03");
LocalTime expected = LocalTime.now(Clock.system(zone));
LocalTime test = LocalTime.now(zone);
for (int i = 0; i < 100; i++) {
for (int i = 0; i < 1000; i++) {
if (expected.equals(test)) {
return;
}
expected = LocalTime.now(Clock.system(zone));
test = LocalTime.now(zone);
}
assertEquals(test, expected);
assertEquals(expected, test);
}

// -----------------------------------------------------------------------
Expand Down Expand Up @@ -1607,10 +1607,12 @@ Iterator<Object[]> plusSeconds_fromZero() {
int min = 59;
int sec = 0;

@Override
public boolean hasNext() {
return i <= 3660;
}

@Override
public Object[] next() {
final Object[] ret = new Object[] { i, hour, min, sec };
i += delta;
Expand All @@ -1633,6 +1635,7 @@ public Object[] next() {
return ret;
}

@Override
public void remove() {
throw new UnsupportedOperationException();
}
Expand Down Expand Up @@ -1724,10 +1727,12 @@ Iterator<Object[]> plusNanos_fromZero() {
int sec = 0;
long nanos = 0;

@Override
public boolean hasNext() {
return i <= 3660 * 1000000000L;
}

@Override
public Object[] next() {
final Object[] ret = new Object[] { i, hour, min, sec, (int) nanos };
i += delta;
Expand Down Expand Up @@ -1755,6 +1760,7 @@ public Object[] next() {
return ret;
}

@Override
public void remove() {
throw new UnsupportedOperationException();
}
Expand Down Expand Up @@ -2100,10 +2106,12 @@ Iterator<Object[]> minusSeconds_fromZero() {
int min = 59;
int sec = 0;

@Override
public boolean hasNext() {
return i >= -3660;
}

@Override
public Object[] next() {
final Object[] ret = new Object[] { i, hour, min, sec };
i -= delta;
Expand All @@ -2126,6 +2134,7 @@ public Object[] next() {
return ret;
}

@Override
public void remove() {
throw new UnsupportedOperationException();
}
Expand Down Expand Up @@ -2232,10 +2241,12 @@ Iterator<Object[]> minusNanos_fromZero() {
int sec = 0;
long nanos = 0;

@Override
public boolean hasNext() {
return i >= -3660 * 1000000000L;
}

@Override
public Object[] next() {
final Object[] ret = new Object[] { i, hour, min, sec, (int) nanos };
i -= delta;
Expand Down Expand Up @@ -2263,6 +2274,7 @@ public Object[] next() {
return ret;
}

@Override
public void remove() {
throw new UnsupportedOperationException();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,8 @@ public void test_toNanoOfDay_fromNanoOfDay_symmetry() {
super.long_test_toNanoOfDay_fromNanoOfDay_symmetry();
}

public void test_now_ZoneId() {
super.disabled_test_now_ZoneId();
}

}

0 comments on commit 1237aa9

Please sign in to comment.