[ 
https://issues.apache.org/jira/browse/SOLR-12877?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16655967#comment-16655967
 ] 

ASF subversion and git services commented on SOLR-12877:
--------------------------------------------------------

Commit 4d811b798976e3213737ffdccd4540e40218d837 in lucene-solr's branch 
refs/heads/branch_7x from [~cpoerschke]
[ https://git-wip-us.apache.org/repos/asf?p=lucene-solr.git;h=4d811b7 ]

SOLR-12877: avoid NPE in TestUtilizeNode.getReplicaList


> reduce test failures due to NullPointerException
> ------------------------------------------------
>
>                 Key: SOLR-12877
>                 URL: https://issues.apache.org/jira/browse/SOLR-12877
>             Project: Solr
>          Issue Type: Test
>            Reporter: Christine Poerschke
>            Priority: Minor
>
> Creating this as an umbrella ticket for fixing various NullPointerExceptions 
> e.g. encounted in this type of code pattern in tests:
> before:
> {code:java}
> Bar bar = foo.getBar(id);
> assertEquals(42, bar.size()); // if bar is null we hit a NPE here
> {code}
> after:
> {code:java}
> Bar bar = foo.getBar(id);
> assertNotNull(bar); // if bar is null the test now fails here
> assertEquals(42, bar.size());
> {code}
> The test failure itself would still remain a test failure but a slightly 
> clearer one perhaps.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to