llama90 commented on code in PR #42158:
URL: https://github.com/apache/arrow/pull/42158#discussion_r1644594471
##########
java/flight/flight-sql-jdbc-core/src/test/java/org/apache/arrow/driver/jdbc/accessor/impl/binary/ArrowFlightJdbcBinaryVectorAccessorTest.java:
##########
@@ -73,61 +67,57 @@ public class ArrowFlightJdbcBinaryVectorAccessorTest {
};
private final
AccessorTestUtils.AccessorIterator<ArrowFlightJdbcBinaryVectorAccessor>
- accessorIterator = new AccessorTestUtils.AccessorIterator<>(collector,
accessorSupplier);
-
- @Parameterized.Parameters(name = "{1}")
- public static Collection<Object[]> data() {
- return Arrays.asList(
- new Object[][] {
- {
- (Supplier<ValueVector>) () ->
rootAllocatorTestRule.createVarBinaryVector(),
- "VarBinaryVector"
- },
- {
- (Supplier<ValueVector>) () ->
rootAllocatorTestRule.createLargeVarBinaryVector(),
- "LargeVarBinaryVector"
- },
- {
- (Supplier<ValueVector>) () ->
rootAllocatorTestRule.createFixedSizeBinaryVector(),
- "FixedSizeBinaryVector"
- },
- });
- }
-
- public ArrowFlightJdbcBinaryVectorAccessorTest(
- Supplier<ValueVector> vectorSupplier, String vectorType) {
- this.vectorSupplier = vectorSupplier;
+ accessorIterator = new
AccessorTestUtils.AccessorIterator<>(accessorSupplier);
+
+ public static Stream<Arguments> data() {
+ return Stream.of(
+ Arguments.of(
+ (Supplier<ValueVector>) () ->
rootAllocatorTestExtension.createVarBinaryVector(),
+ "VarBinaryVector"),
+ Arguments.of(
+ (Supplier<ValueVector>) () ->
rootAllocatorTestExtension.createLargeVarBinaryVector(),
+ "LargeVarBinaryVector"),
+ Arguments.of(
+ (Supplier<ValueVector>) () ->
rootAllocatorTestExtension.createFixedSizeBinaryVector(),
+ "FixedSizeBinaryVector"));
}
- @Before
- public void setup() {
+ public void setup(Supplier<ValueVector> vectorSupplier) {
this.vector = vectorSupplier.get();
}
- @After
+ @AfterEach
public void tearDown() {
this.vector.close();
}
- @Test
- public void testShouldGetStringReturnExpectedString() throws Exception {
+ @ParameterizedTest
+ @MethodSource("data")
+ public void testShouldGetStringReturnExpectedString(Supplier<ValueVector>
vectorSupplier)
+ throws Exception {
+ setup(vectorSupplier);
Review Comment:
Based on the information provided by @lidavidm, it will eventually be
improved in the future.
> It appears https://github.com/junit-team/junit5/issues/878 is the feature
request.
- https://github.com/apache/arrow/pull/42029#discussion_r1635828456
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]