equal
deleted
inserted
replaced
22 */ |
22 */ |
23 |
23 |
24 /* @test |
24 /* @test |
25 * @summary Basic functional test of OptionalLong |
25 * @summary Basic functional test of OptionalLong |
26 * @author Mike Duigou |
26 * @author Mike Duigou |
|
27 * @build ObscureException |
27 * @run testng BasicLong |
28 * @run testng BasicLong |
28 */ |
29 */ |
29 |
30 |
30 import java.util.NoSuchElementException; |
31 import java.util.NoSuchElementException; |
31 import java.util.OptionalLong; |
32 import java.util.OptionalLong; |
199 long[] es = s.toArray(); |
200 long[] es = s.toArray(); |
200 assertEquals(es.length, 1); |
201 assertEquals(es.length, 1); |
201 assertEquals(es[0], 42L); |
202 assertEquals(es[0], 42L); |
202 } |
203 } |
203 } |
204 } |
204 |
|
205 private static class ObscureException extends RuntimeException { |
|
206 |
|
207 } |
|
208 } |
205 } |