-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add failing tests for reading just produced output avro files. #578
base: master
Are you sure you want to change the base?
Conversation
Print user-provided Avro schema to a log.
dbeam-core/src/main/java/com/spotify/dbeam/avro/BeamJdbcAvroSchema.java
Outdated
Show resolved
Hide resolved
dbeam-core/src/test/java/com/spotify/dbeam/jobs/JdbcAvroJobTest.java
Outdated
Show resolved
Hide resolved
dbeam-core/src/test/java/com/spotify/dbeam/jobs/JdbcAvroJobTest.java
Outdated
Show resolved
Hide resolved
int result = | ||
new DataFileReadTool() | ||
.run(System.in, System.out, System.err, Arrays.asList("--head", outputAvroFile)); | ||
Assert.assertEquals(0, result); // old school :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does "old school :)" mean?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
0 returned meaning "success".
|
||
int result = | ||
new DataFileReadTool() | ||
.run(System.in, System.out, System.err, Arrays.asList("--head", outputAvroFile)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need DataFileReadTool from a separate jar. Can we simply use something like the other tests is using, readAvroRecords(outputPath.resolve("part-00000-of-00001.avro").toFile(), schema)
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess the idea is to use an "independent" but trustworthy tool to illustrate real-world usage.
…hema.java Co-authored-by: Luís Bianchin <labianchin@users.noreply.github.com>
…t.java Co-authored-by: Luís Bianchin <labianchin@users.noreply.github.com>
…t.java Co-authored-by: Luís Bianchin <labianchin@users.noreply.github.com>
Print user-provided Avro schema to a log.
Unit-tests to illustrate existing issues when incorrect user-supplied Avro schema is used. #579
Testing
Checklist for PR author(s)
mvn com.coveo:fmt-maven-plugin:format org.codehaus.mojo:license-maven-plugin:update-file-header
)