Search in sources :

Example 31 with NullPointerTester

use of com.google.common.testing.NullPointerTester in project guava by google.

the class FunctionsTest method testNullPointerExceptions.

// NullPointerTester
@GwtIncompatible
public void testNullPointerExceptions() {
    NullPointerTester tester = new NullPointerTester();
    tester.testAllPublicStaticMethods(Functions.class);
}
Also used : NullPointerTester(com.google.common.testing.NullPointerTester) GwtIncompatible(com.google.common.annotations.GwtIncompatible)

Example 32 with NullPointerTester

use of com.google.common.testing.NullPointerTester in project guava by google.

the class TypeTokenTest method testNulls.

public <T> void testNulls() {
    new NullPointerTester().testAllPublicStaticMethods(TypeToken.class);
    new NullPointerTester().setDefault(TypeParameter.class, new TypeParameter<T>() {
    }).testAllPublicInstanceMethods(TypeToken.of(String.class));
}
Also used : NullPointerTester(com.google.common.testing.NullPointerTester)

Example 33 with NullPointerTester

use of com.google.common.testing.NullPointerTester in project guava by google.

the class FluentIterableTest method testNullPointerExceptions.

// NullPointerTester
@GwtIncompatible
public void testNullPointerExceptions() {
    NullPointerTester tester = new NullPointerTester();
    tester.testAllPublicStaticMethods(FluentIterable.class);
}
Also used : NullPointerTester(com.google.common.testing.NullPointerTester) GwtIncompatible(com.google.common.annotations.GwtIncompatible)

Example 34 with NullPointerTester

use of com.google.common.testing.NullPointerTester in project guava by google.

the class LocalLoadingCacheTest method testNullParameters.

// null parameters test
public void testNullParameters() throws Exception {
    NullPointerTester tester = new NullPointerTester();
    CacheLoader<Object, Object> loader = identityLoader();
    tester.testAllPublicInstanceMethods(makeCache(createCacheBuilder(), loader));
}
Also used : NullPointerTester(com.google.common.testing.NullPointerTester)

Example 35 with NullPointerTester

use of com.google.common.testing.NullPointerTester in project guava by google.

the class EnumBiMapTest method testNulls.

// reflection
@GwtIncompatible
public void testNulls() {
    new NullPointerTester().testAllPublicStaticMethods(EnumBiMap.class);
    new NullPointerTester().testAllPublicInstanceMethods(EnumBiMap.create(ImmutableMap.of(Currency.DOLLAR, Country.CHILE)));
}
Also used : NullPointerTester(com.google.common.testing.NullPointerTester) GwtIncompatible(com.google.common.annotations.GwtIncompatible)

Aggregations

NullPointerTester (com.google.common.testing.NullPointerTester)171 GwtIncompatible (com.google.common.annotations.GwtIncompatible)100 Test (org.junit.Test)26 UnhashableObject (com.google.common.collect.testing.UnhashableObject)2 BoundedContext (io.spine.server.BoundedContext)2 FileSystem (java.nio.file.FileSystem)2 Sets.newEnumSet (com.google.common.collect.Sets.newEnumSet)1 Sets.newHashSet (com.google.common.collect.Sets.newHashSet)1 Sets.powerSet (com.google.common.collect.Sets.powerSet)1 AnEnum (com.google.common.collect.testing.AnEnum)1 SafeTreeSet (com.google.common.collect.testing.SafeTreeSet)1 ExecutionList (com.google.common.util.concurrent.ExecutionList)1 BuildConfiguration (com.google.devtools.build.lib.analysis.config.BuildConfiguration)1 FieldDescriptor (com.google.protobuf.Descriptors.FieldDescriptor)1 StringValue (com.google.protobuf.StringValue)1 TestActorRequestFactory (io.spine.client.TestActorRequestFactory)1 Command (io.spine.core.Command)1 EventEnvelope (io.spine.core.EventEnvelope)1 AnAggregateRoot (io.spine.server.aggregate.given.AggregateRootTestEnv.AnAggregateRoot)1 TestEventFactory (io.spine.server.command.TestEventFactory)1