Rishavbhattarai opened a new pull request, #40871: URL: https://github.com/apache/beam/pull/40871
Fixes #18689. Ports `BigQueryIOWriteTest` off the deprecated `DoFnTester`. The only use was in `testWritePartition`. Unlike the Datastore and SDF tests, nothing here blocks `TestPipeline`: `WritePartition` is serializable and holds no mocks. So the test now runs it through the class's existing `p`: - the file list goes in as one `Iterable` element, the way `BatchLoads` hands it over, so there's one bundle - the temp file prefix is a real side input instead of `setSideInput` - both outputs get `KvCoder.of(ShardedKeyCoder.of(TableDestinationCoder.of()), WritePartition.ResultCoder.INSTANCE)`, matching `BatchLoads` - the existing checks moved into `PAssert.satisfies` on the expected tag, unchanged except that the empty-table check uses `File.length()` (no checked exception inside the lambda) `enableAbandonedNodeEnforcement(false)` is gone since the pipeline now runs. The two `Create`s got names to keep transform names stable. The empty singleton file is still deleted after the check, because `tearDown` asserts the temp dir has no files. Testing: `./gradlew :sdks:java:io:google-cloud-platform:test --tests 'org.apache.beam.sdk.io.gcp.bigquery.BigQueryIOWriteTest*'` passes (220 run, 98 skipped, 0 failures), and `spotlessCheck` is clean. To make sure the `PAssert` actually runs, I changed the expected partition count in `testWritePartitionLargeFileSize` from 4 to 5 and both parameterizations failed. -- 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]
