Skip to content

Commit

Permalink
Fix integration tests that fell out from some benchmarking.
Browse files Browse the repository at this point in the history
  • Loading branch information
swankjesse committed Jul 15, 2011
1 parent 9cf579e commit 3c4d121
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion extras/src/main/java/com/google/gson/mini/MiniGson.java
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,10 @@ private MiniGson(Builder builder) {
factories.add(TypeAdapters.DOUBLE_FACTORY);
factories.add(TypeAdapters.LONG_FACTORY);
factories.add(TypeAdapters.STRING_FACTORY);
factories.add(ReflectiveTypeAdapter.FACTORY);
factories.add(CollectionTypeAdapter.FACTORY);
factories.add(StringToValueMapTypeAdapter.FACTORY);
factories.add(ArrayTypeAdapter.FACTORY);
factories.add(ReflectiveTypeAdapter.FACTORY);
this.factories = Collections.unmodifiableList(factories);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ private Map<String, BoundField<?>> getBoundFields(
Map<String, BoundField<?>> result = new LinkedHashMap<String, BoundField<?>>();
while (raw != Object.class) {
for (Field field : raw.getDeclaredFields()) {
field.setAccessible(true); // TODO: don't call setAccessible unless necessary
Type fieldType = $Gson$Types.resolve(type.getType(), raw, field.getGenericType());
BoundField<?> boundField = BoundField.create(context, field, TypeToken.get(fieldType));
result.put(boundField.name, boundField);
Expand Down

0 comments on commit 3c4d121

Please sign in to comment.