You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Christine Poerschke (JIRA)" <ji...@apache.org> on 2018/10/16 16:48:00 UTC
[jira] [Created] (SOLR-12877) reduce test failures due to
NullPointerException
Christine Poerschke created SOLR-12877:
------------------------------------------
Summary: 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
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: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org