Skip to content

Conversation

@RachelTucker
Copy link
Contributor

All constructors with stream or channel inputs now have a negative test to verify preconditions are working as expected. This consists of all constructors for:

  • GetObjectRequest
  • PutObjectRequest
  • PutMultiPartUploadPartRequest

Note: each tests is catching two exceptions. The null pointer exception is thrown by the precondition in the constructor (expected), and the illegal argument exception is thrown in IntelliJ IDEA due to the Nonnull annotation.

try {
new GetObjectRequest("BucketName", "ObjectName", null);
fail();
} catch (final NullPointerException e) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm confused. Which of these catch clauses is the expected one?

@rpmoore rpmoore merged commit a49a2b6 into SpectraLogic:master Sep 8, 2017
@RachelTucker RachelTucker deleted the JSDK-257 branch September 8, 2017 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants