1 /* 2 * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * This code is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. 8 * 9 * This code is distributed in the hope that it will be useful, but WITHOUT 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 12 * version 2 for more details (a copy is included in the LICENSE file that 13 * accompanied this code). 14 * 15 * You should have received a copy of the GNU General Public License version 16 * 2 along with this work; if not, write to the Free Software Foundation, 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 18 * 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 20 * or visit www.oracle.com if you need additional information or have any 21 * questions. 22 */ 23 24 /** 25 * @test 26 * @bug 8148838 27 */ 28 29 package org.openjdk.tests.java.util.stream; 30 31 import java.util.Arrays; 32 import java.util.Comparator; 33 import java.util.List; 34 import java.util.Spliterator; 35 import java.util.function.Consumer; 36 import java.util.function.DoubleConsumer; 37 import java.util.function.Function; 38 import java.util.function.IntConsumer; 39 import java.util.function.LongConsumer; 40 import java.util.function.UnaryOperator; 41 import java.util.stream.DoubleStream; 42 import java.util.stream.DoubleStreamTestDataProvider; 43 import java.util.stream.IntStream; 44 import java.util.stream.IntStreamTestDataProvider; 45 import java.util.stream.LambdaTestHelpers; 46 import java.util.stream.LongStream; 47 import java.util.stream.LongStreamTestDataProvider; 48 import java.util.stream.OpTestCase; 49 import java.util.stream.SpliteratorTestHelper; 50 import java.util.stream.Stream; 51 import java.util.stream.StreamSupport; 52 import java.util.stream.StreamTestDataProvider; 53 import java.util.stream.TestData; 54 55 import org.testng.Assert; 56 import org.testng.annotations.Test; 57 58 import static java.util.stream.LambdaTestHelpers.countTo; 59 import static java.util.stream.LambdaTestHelpers.dpEven; 60 import static java.util.stream.LambdaTestHelpers.ipEven; 61 import static java.util.stream.LambdaTestHelpers.irDoubler; 62 import static java.util.stream.LambdaTestHelpers.lpEven; 63 import static java.util.stream.LambdaTestHelpers.mDoubler; 64 import static java.util.stream.LambdaTestHelpers.pEven; 65 import static java.util.stream.LambdaTestHelpers.permuteStreamFunctions; 66 67 @Test 68 public class StreamSpliteratorTest extends OpTestCase { 69 | 1 /* 2 * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * This code is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. 8 * 9 * This code is distributed in the hope that it will be useful, but WITHOUT 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 12 * version 2 for more details (a copy is included in the LICENSE file that 13 * accompanied this code). 14 * 15 * You should have received a copy of the GNU General Public License version 16 * 2 along with this work; if not, write to the Free Software Foundation, 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 18 * 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 20 * or visit www.oracle.com if you need additional information or have any 21 * questions. 22 */ 23 24 /** 25 * @test 26 * @bug 8148838 27 */ 28 29 package org.openjdk.tests.java.util.stream; 30 31 import java.util.Arrays; 32 import java.util.Comparator; 33 import java.util.List; 34 import java.util.Spliterator; 35 import java.util.SpliteratorTestHelper; 36 import java.util.function.Consumer; 37 import java.util.function.DoubleConsumer; 38 import java.util.function.Function; 39 import java.util.function.IntConsumer; 40 import java.util.function.LongConsumer; 41 import java.util.function.UnaryOperator; 42 import java.util.stream.DoubleStream; 43 import java.util.stream.DoubleStreamTestDataProvider; 44 import java.util.stream.IntStream; 45 import java.util.stream.IntStreamTestDataProvider; 46 import java.util.stream.LambdaTestHelpers; 47 import java.util.stream.LongStream; 48 import java.util.stream.LongStreamTestDataProvider; 49 import java.util.stream.OpTestCase; 50 import java.util.stream.Stream; 51 import java.util.stream.StreamSupport; 52 import java.util.stream.StreamTestDataProvider; 53 import java.util.stream.TestData; 54 55 import org.testng.Assert; 56 import org.testng.annotations.Test; 57 58 import static java.util.stream.LambdaTestHelpers.countTo; 59 import static java.util.stream.LambdaTestHelpers.dpEven; 60 import static java.util.stream.LambdaTestHelpers.ipEven; 61 import static java.util.stream.LambdaTestHelpers.irDoubler; 62 import static java.util.stream.LambdaTestHelpers.lpEven; 63 import static java.util.stream.LambdaTestHelpers.mDoubler; 64 import static java.util.stream.LambdaTestHelpers.pEven; 65 import static java.util.stream.LambdaTestHelpers.permuteStreamFunctions; 66 67 @Test 68 public class StreamSpliteratorTest extends OpTestCase { 69 |