Skip to content

Commit d9c8ab6

Browse files
committed
Fix FormDataMapTest anonymous FormValue missing undertow 2.2.x methods
Add getCharset(), getFileItem(), isFileItem(), and isBigField() stubs to the anonymous FormData.FormValue in addInMemoryFileValue(). These abstract methods were added in undertow 2.2.x and caused compilation failure when the latestDepForkedTest resolved the latest 2.2.x release.
1 parent a15be2f commit d9c8ab6

1 file changed

Lines changed: 21 additions & 0 deletions

File tree

  • dd-java-agent/instrumentation/undertow/undertow-2.0/src/test/java/datadog/trace/instrumentation/undertow

dd-java-agent/instrumentation/undertow/undertow-2.0/src/test/java/datadog/trace/instrumentation/undertow/FormDataMapTest.java

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,27 @@ public File getFile() {
132132
public HeaderMap getHeaders() {
133133
return null;
134134
}
135+
136+
// Methods added in undertow 2.2.x
137+
@Override
138+
public String getCharset() {
139+
return null;
140+
}
141+
142+
@Override
143+
public FormData.FileItem getFileItem() {
144+
return null;
145+
}
146+
147+
@Override
148+
public boolean isFileItem() {
149+
return false;
150+
}
151+
152+
@Override
153+
public boolean isBigField() {
154+
return false;
155+
}
135156
};
136157

137158
Deque<FormData.FormValue> deque = new ArrayDeque<>();

0 commit comments

Comments
 (0)