/external/gson/gson/src/test/java/com/google/gson/functional/ |
D | NamingPolicyTest.java | 46 Gson gson = builder.setFieldNamingPolicy(FieldNamingPolicy.UPPER_CAMEL_CASE).create(); in testGsonWithNonDefaultFieldNamingPolicySerialization() local 53 Gson gson = builder.setFieldNamingPolicy(FieldNamingPolicy.UPPER_CAMEL_CASE).create(); in testGsonWithNonDefaultFieldNamingPolicyDeserialiation() local 60 Gson gson = builder.setFieldNamingPolicy(FieldNamingPolicy.LOWER_CASE_WITH_DASHES).create(); in testGsonWithLowerCaseDashPolicySerialization() local 67 Gson gson = builder.setFieldNamingPolicy(FieldNamingPolicy.LOWER_CASE_WITH_DOTS).create(); in testGsonWithLowerCaseDotPolicySerialization() local 74 Gson gson = builder.setFieldNamingPolicy(FieldNamingPolicy.LOWER_CASE_WITH_DOTS).create(); in testGsonWithLowerCaseDotPolicyDeserialiation() local 81 Gson gson = builder.setFieldNamingPolicy(FieldNamingPolicy.LOWER_CASE_WITH_DASHES).create(); in testGsonWithLowerCaseDashPolicyDeserialiation() local 88 Gson gson = builder.setFieldNamingPolicy(FieldNamingPolicy.LOWER_CASE_WITH_UNDERSCORES) in testGsonWithLowerCaseUnderscorePolicySerialization() local 96 Gson gson = builder.setFieldNamingPolicy(FieldNamingPolicy.LOWER_CASE_WITH_UNDERSCORES) in testGsonWithLowerCaseUnderscorePolicyDeserialiation() local 104 Gson gson = builder.create(); in testGsonWithSerializedNameFieldNamingPolicySerialization() local 111 Gson gson = builder.create(); in testGsonWithSerializedNameFieldNamingPolicyDeserialization() local [all …]
|
D | ReflectionAccessFilterTest.java | 45 Gson gson = new GsonBuilder() in testBlockInaccessibleJava() local 80 Gson gson = new GsonBuilder() in testBlockInaccessibleJavaExtendingJdkClass() local 99 Gson gson = new GsonBuilder() in testBlockAllJava() local 118 Gson gson = new GsonBuilder() in testBlockAllJavaExtendingJdkClass() local 142 Gson gson = new GsonBuilder() in testBlockInaccessibleStaticField() local 179 Gson gson = new GsonBuilder() in testDelegation() local 225 Gson gson = new GsonBuilder() in testAllowForSupertype() local 268 Gson gson = new GsonBuilder() in testInaccessibleNoArgsConstructor() local 306 Gson gson = gsonBuilder.create(); in testClassWithoutNoArgsConstructor() local 353 Gson gson = new GsonBuilder() in testBlockAllPartial() local [all …]
|
D | TypeAdapterPrecedenceTest.java | 36 Gson gson = new GsonBuilder() in testNonstreamingFollowedByNonstreaming() local 47 Gson gson = new GsonBuilder() in testStreamingFollowedByStreaming() local 56 Gson gson = new GsonBuilder() in testSerializeNonstreamingTypeAdapterFollowedByStreamingTypeAdapter() local 66 Gson gson = new GsonBuilder() in testStreamingFollowedByNonstreaming() local 76 Gson gson = new GsonBuilder() in testStreamingHierarchicalFollowedByNonstreaming() local 86 Gson gson = new GsonBuilder() in testStreamingFollowedByNonstreamingHierarchical() local 96 Gson gson = new GsonBuilder() in testStreamingHierarchicalFollowedByNonstreamingHierarchical() local 106 Gson gson = new GsonBuilder() in testNonstreamingHierarchicalFollowedByNonstreaming() local
|
D | NullObjectAndFieldTest.java | 52 Gson gson = gsonBuilder.create(); in testTopLevelNullObjectSerialization() local 61 Gson gson = gsonBuilder.create(); in testTopLevelNullObjectDeserialization() local 67 Gson gson = gsonBuilder.create(); in testExplicitSerializationOfNulls() local 75 Gson gson = gsonBuilder.create(); in testExplicitDeserializationOfNulls() local 81 Gson gson = gsonBuilder.create(); in testExplicitSerializationOfNullArrayMembers() local 91 Gson gson = gsonBuilder.serializeNulls().create(); in testNullWrappedPrimitiveMemberSerialization() local 101 Gson gson = gsonBuilder.create(); in testNullWrappedPrimitiveMemberDeserialization() local 108 Gson gson = gsonBuilder.create(); in testExplicitSerializationOfNullCollectionMembers() local 115 Gson gson = gsonBuilder.create(); in testExplicitSerializationOfNullStringMembers() local 123 Gson gson = gsonBuilder.create(); in testCustomSerializationOfNulls() local [all …]
|
D | ToNumberPolicyFunctionalTest.java | 36 Gson gson = new Gson(); in testDefault() local 44 Gson gson = new GsonBuilder() in testAsDoubles() local 55 Gson gson = new GsonBuilder() in testAsLazilyParsedNumbers() local 66 Gson gson = new GsonBuilder() in testAsLongsOrDoubles() local 79 Gson gson = new GsonBuilder() in testAsBigDecimals() local 94 Gson gson = new GsonBuilder() in testAsListOfLongsOrDoubles() local 117 Gson gson = new GsonBuilder() in testCustomStrategiesCannotAffectConcreteDeclaredNumbers() local
|
D | CustomTypeAdaptersTest.java | 56 Gson gson = builder.registerTypeAdapter( in testCustomSerializers() local 71 Gson gson = new GsonBuilder().registerTypeAdapter( in testCustomDeserializers() local 87 Gson gson = createGsonObjectWithFooTypeAdapter(); in disable_testCustomSerializersOfSelf() local 97 Gson gson = createGsonObjectWithFooTypeAdapter(); in disable_testCustomDeserializersOfSelf() local 108 Gson gson = new GsonBuilder().registerTypeAdapter( in testCustomNestedSerializers() local 120 Gson gson = new GsonBuilder().registerTypeAdapter( in testCustomNestedDeserializers() local 134 Gson gson = new GsonBuilder().registerTypeAdapter(Base.class, new JsonSerializer<Base> () { in testCustomTypeAdapterDoesNotAppliesToSubClasses() local 151 Gson gson = new GsonBuilder().registerTypeAdapter(Base.class, new JsonSerializer<Base> () { in testCustomTypeAdapterAppliesToSubClassesSerializedAsBaseClass() local 210 Gson gson = new GsonBuilder() in testCustomSerializerInvokedForPrimitives() local 222 Gson gson = new GsonBuilder() in testCustomDeserializerInvokedForPrimitives() local [all …]
|
D | VersioningTest.java | 49 Gson gson = gsonWithVersion(1.29); in testVersionedUntilSerialization() local 66 Gson gson = gsonWithVersion(1.29); in testVersionedUntilDeserialization() local 81 Gson gson = gsonWithVersion(1.0); in testVersionedClassesSerialization() local 89 Gson gson = gsonWithVersion(1.0); in testVersionedClassesDeserialization() local 102 Gson gson = gsonWithVersion(1.0); in testIgnoreLaterVersionClassSerialization() local 108 Gson gson = gsonWithVersion(1.0); in testIgnoreLaterVersionClassDeserialization() local 118 Gson gson = gsonWithVersion(1.0); in testVersionedGsonWithUnversionedClassesSerialization() local 125 Gson gson = gsonWithVersion(1.0); in testVersionedGsonWithUnversionedClassesDeserialization() local 138 Gson gson = gsonWithVersion(1.0); in testVersionedGsonMixingSinceAndUntilSerialization() local 159 Gson gson = gsonWithVersion(1.0); in testVersionedGsonMixingSinceAndUntilDeserialization() local
|
D | ExclusionStrategyFunctionalTest.java | 57 Gson gson = createGson(new MyExclusionStrategy(String.class), true); in testExclusionStrategySerialization() local 66 Gson gson = createGson(new MyExclusionStrategy(String.class), true); in testExclusionStrategySerializationDoesNotImpactDeserialization() local 74 Gson gson = createGson(new MyExclusionStrategy(String.class), false); in testExclusionStrategyDeserialization() local 89 Gson gson = createGson(new MyExclusionStrategy(String.class), false); in testExclusionStrategySerializationDoesNotImpactSerialization() local 101 Gson gson = createGson(new MyExclusionStrategy(String.class), false); in testExclusionStrategyWithMode() local 116 Gson gson = new GsonBuilder() in testExcludeTopLevelClassSerialization() local 123 Gson gson = new GsonBuilder() in testExcludeTopLevelClassSerializationDoesNotImpactDeserialization() local 134 Gson gson = new GsonBuilder() in testExcludeTopLevelClassDeserialization() local 143 Gson gson = new GsonBuilder() in testExcludeTopLevelClassDeserializationDoesNotImpactSerialization() local
|
D | FieldNamingTest.java | 34 Gson gson = getGsonWithNamingPolicy(IDENTITY); in testIdentity() local 42 Gson gson = getGsonWithNamingPolicy(UPPER_CAMEL_CASE); in testUpperCamelCase() local 50 Gson gson = getGsonWithNamingPolicy(UPPER_CAMEL_CASE_WITH_SPACES); in testUpperCamelCaseWithSpaces() local 58 Gson gson = getGsonWithNamingPolicy(UPPER_CASE_WITH_UNDERSCORES); in testUpperCaseWithUnderscores() local 66 Gson gson = getGsonWithNamingPolicy(LOWER_CASE_WITH_UNDERSCORES); in testLowerCaseWithUnderscores() local 74 Gson gson = getGsonWithNamingPolicy(LOWER_CASE_WITH_DASHES); in testLowerCaseWithDashes() local
|
D | SecurityTest.java | 45 Gson gson = gsonBuilder.generateNonExecutableJson().create(); in testNonExecutableJsonSerialization() local 52 Gson gson = gsonBuilder.create(); in testNonExecutableJsonDeserialization() local 58 Gson gson = gsonBuilder.generateNonExecutableJson().create(); in testJsonWithNonExectuableTokenSerialization() local 68 Gson gson = gsonBuilder.create(); in testJsonWithNonExectuableTokenWithRegularGsonDeserialization() local 80 Gson gson = gsonBuilder.generateNonExecutableJson().create(); in testJsonWithNonExectuableTokenWithConfiguredGsonDeserialization() local
|
D | CustomSerializerTest.java | 46 Gson gson = new GsonBuilder() in testBaseClassSerializerInvokedForBaseClassFields() local 57 Gson gson = new GsonBuilder() in testSubClassSerializerInvokedForBaseClassFieldsHoldingSubClassInstances() local 68 Gson gson = new GsonBuilder() in testSubClassSerializerInvokedForBaseClassFieldsHoldingArrayOfSubClassInstances() local 82 Gson gson = new GsonBuilder() in testBaseClassSerializerInvokedForBaseClassFieldsHoldingSubClassInstances() local 92 Gson gson = new GsonBuilder() in testSerializerReturnsNull() local
|
D | TypeAdapterRuntimeTypeWrapperTest.java | 44 Gson gson = new GsonBuilder() in testJsonSerializer() local 64 Gson gson = new GsonBuilder() in testJsonDeserializer_ReflectiveSerializerDelegate() local 79 Gson gson = new GsonBuilder() in testJsonDeserializer_CustomSerializerDelegate() local 105 Gson gson = new GsonBuilder() in testJsonDeserializer_ReflectiveTreeSerializerDelegate() local 122 Gson gson = new GsonBuilder() in testJsonDeserializer_JsonSerializerDelegate() local 147 Gson gson = new GsonBuilder() in testJsonDeserializer_SubclassBackwardCompatibility() local
|
D | InstanceCreatorTest.java | 42 Gson gson = new GsonBuilder() in testInstanceCreatorReturnsBaseType() local 55 Gson gson = new GsonBuilder() in testInstanceCreatorReturnsSubTypeForTopLevelObject() local 73 Gson gson = new GsonBuilder() in testInstanceCreatorReturnsSubTypeForField() local 96 Gson gson = new GsonBuilder() in testInstanceCreatorForCollectionType() local 112 Gson gson = new GsonBuilder() in testInstanceCreatorForParametrizedType() local
|
D | JsonAdapterAnnotationOnClassesTest.java | 45 Gson gson = new Gson(); in testJsonAdapterInvoked() local 63 Gson gson = new Gson(); in testJsonAdapterFactoryInvoked() local 79 Gson gson = new GsonBuilder() in testRegisteredAdapterOverridesJsonAdapter() local 96 Gson gson = new GsonBuilder() in testRegisteredSerializerOverridesJsonAdapter() local 115 Gson gson = new GsonBuilder() in testRegisteredDeserializerOverridesJsonAdapter() local 137 Gson gson = new Gson(); in testNullSafeObjectFromJson() local 166 @Override public <T> TypeAdapter<T> create(Gson gson, final TypeToken<T> type) { in create()
|
D | MapAsArrayTypeAdapterTest.java | 33 Gson gson = new GsonBuilder() in testSerializeComplexMapWithTypeAdapter() local 57 Gson gson = new GsonBuilder() in disabled_testTwoTypesCollapseToOneSerialize() local 72 Gson gson = new GsonBuilder() in testTwoTypesCollapseToOneDeserialize() local 86 Gson gson = new GsonBuilder() in testMultipleEnableComplexKeyRegistrationHasNoEffect() local 100 Gson gson = new GsonBuilder().enableComplexMapKeySerialization().create(); in testMapWithTypeVariableSerialization() local 109 Gson gson = new GsonBuilder().enableComplexMapKeySerialization().create(); in testMapWithTypeVariableDeserialization() local
|
D | JsonAdapterAnnotationOnFieldsTest.java | 39 Gson gson = new Gson(); in testClassAnnotationAdapterTakesPrecedenceOverDefault() local 47 Gson gson = new Gson(); in testClassAnnotationAdapterFactoryTakesPrecedenceOverDefault() local 55 Gson gson = new GsonBuilder() in testRegisteredTypeAdapterTakesPrecedenceOverClassAnnotationAdapter() local 65 Gson gson = new GsonBuilder() in testFieldAnnotationTakesPrecedenceOverRegisteredTypeAdapter() local 81 Gson gson = new Gson(); in testFieldAnnotationTakesPrecedenceOverClassAnnotation() local 122 @Override public <T> TypeAdapter<T> create(Gson gson, final TypeToken<T> type) { in create()
|
D | DefaultTypeAdaptersTest.java | 67 private Gson gson; field in DefaultTypeAdaptersTest 189 public static void testNullSerializationAndDeserialization(Gson gson, Class<?> c) { in testNullSerializationAndDeserialization() 294 Gson gson = new Gson(); in testSetSerialization() local 305 Gson gson = new Gson(); in testBitSetSerialization() local 320 Gson gson = new Gson(); in testBitSetDeserialization() local 382 Gson gson = new GsonBuilder().create(); in testDefaultDateSerializationUsingBuilder() local 393 Gson gson = new GsonBuilder().create(); in testDefaultDateDeserializationUsingBuilder() local 401 Gson gson = new GsonBuilder().create(); in testDefaultCalendarSerialization() local 412 Gson gson = new GsonBuilder().create(); in testDefaultCalendarDeserialization() local 424 Gson gson = new GsonBuilder().create(); in testDefaultGregorianCalendarSerialization() local [all …]
|
D | CustomDeserializerTest.java | 43 private Gson gson; field in CustomDeserializerTest 115 Gson gson = new GsonBuilder().registerTypeAdapter(MyBase.class, new JsonDeserializer<MyBase>() { in testJsonTypeFieldBasedDeserialization() local 152 Gson gson = new GsonBuilder() in testCustomDeserializerReturnsNullForTopLevelObject() local 166 Gson gson = new GsonBuilder() in testCustomDeserializerReturnsNull() local 180 Gson gson = new GsonBuilder() in testCustomDeserializerReturnsNullForArrayElements() local 195 Gson gson = new GsonBuilder() in testCustomDeserializerReturnsNullForArrayElementsForArrayField() local
|
/external/gson/gson/src/test/java/com/google/gson/ |
D | MixedStreamTest.java | 51 Gson gson = new Gson(); in testWriteMixedStreamed() local 66 Gson gson = new Gson(); in testReadMixedStreamed() local 78 Gson gson = new Gson(); in testReaderDoesNotMutateState() local 92 Gson gson = new Gson(); in testWriteDoesNotMutateState() local 110 Gson gson = new Gson(); in testReadInvalidState() local 122 Gson gson = new Gson(); in testReadClosed() local 133 Gson gson = new Gson(); in testWriteInvalidState() local 144 Gson gson = new Gson(); in testWriteClosed() local 157 Gson gson = new Gson(); in testWriteNulls() local 170 Gson gson = new Gson(); in testReadNulls() local
|
D | GsonBuilderTest.java | 50 Gson gson = builder.create(); in testCreatingMoreThanOnce() local 73 Gson gson = gsonBuilder.create(); in testModificationAfterCreate() local 105 private static void assertDefaultGson(Gson gson) { in assertDefaultGson() 119 private static void assertCustomGson(Gson gson) { in assertCustomGson() 148 Gson gson = new GsonBuilder() in testExcludeFieldsWithModifiers() local 164 Gson gson = new GsonBuilder() in testTransientFieldExclusion() local 191 Gson gson = new GsonBuilder() in testDisableJdkUnsafe() local
|
D | LongSerializationPolicyTest.java | 40 Gson gson = new GsonBuilder() in testDefaultLongSerializationIntegration() local 51 Gson gson = new GsonBuilder() in testDefaultLongSerializationNull() local 68 Gson gson = new GsonBuilder() in testStringLongSerializationIntegration() local 79 Gson gson = new GsonBuilder() in testStringLongSerializationNull() local
|
D | OverrideCoreTypeAdaptersTest.java | 49 Gson gson = new GsonBuilder() in testOverrideWrapperBooleanAdapter() local 60 Gson gson = new GsonBuilder() in testOverridePrimitiveBooleanAdapter() local 71 Gson gson = new GsonBuilder() in testOverrideStringAdapter() local
|
D | GsonTest.java | 58 Gson gson = new Gson(CUSTOM_EXCLUDER, CUSTOM_FIELD_NAMING_STRATEGY, in testOverridesDefaultExcluder() local 96 Gson gson = new Gson(); in testGetAdapter_Null() local 120 Gson gson = new GsonBuilder() in testGetAdapter_Concurrency() local 230 Gson gson = new Gson(); in testDefaultGsonNewBuilderModification() local 262 private static void assertDefaultGson(Gson gson) { in assertDefaultGson() 282 Gson gson = new GsonBuilder() in testNewBuilderModification() local 345 private static void assertCustomGson(Gson gson) { in assertCustomGson()
|
/external/gson/extras/src/test/java/com/google/gson/typeadapters/ |
D | RuntimeTypeAdapterFactoryTest.java | 31 Gson gson = new GsonBuilder() in testRuntimeTypeAdapter() local 52 Gson gson = new GsonBuilder() in testRuntimeTypeAdapterRecognizeSubtypes() local 69 Gson gson = new GsonBuilder() in testRuntimeTypeIsBaseType() local 142 Gson gson = new GsonBuilder() in testDeserializeMissingTypeField() local 155 Gson gson = new GsonBuilder() in testDeserializeMissingSubtype() local 168 Gson gson = new GsonBuilder() in testSerializeMissingSubtype() local 181 Gson gson = new GsonBuilder() in testSerializeCollidingTypeFieldName() local 195 Gson gson = new GsonBuilder() in testSerializeWrappedNullValue() local
|
/external/gson/extras/src/test/java/com/google/gson/graph/ |
D | GraphAdapterBuilderTest.java | 47 Gson gson = gsonBuilder.create(); in testSerialization() local 65 Gson gson = gsonBuilder.create(); in testDeserialization() local 84 Gson gson = gsonBuilder.create(); in testDeserializationDirectSelfReference() local 105 Gson gson = gsonBuilder.create(); in testSerializeListOfLists() local 121 Gson gson = gsonBuilder.create(); in testDeserializeListOfLists() local 140 Gson gson = gsonBuilder.create(); in testSerializationWithMultipleTypes() local 155 Gson gson = gsonBuilder.create(); in testDeserializationWithMultipleTypes() local
|