use of com.palantir.dialogue.BinaryRequestBody in project dialogue by palantir.
the class ConjureBodySerDeTest method testRepeatableBinaryRequestBodyProducesRepeatableRequest.
@Test
public void testRepeatableBinaryRequestBodyProducesRepeatableRequest() {
BodySerDe serde = DefaultConjureRuntime.builder().build().bodySerDe();
RequestBody requestBody = serde.serialize(new BinaryRequestBody() {
@Override
public void write(OutputStream _requestBody) {
}
@Override
public boolean repeatable() {
return true;
}
});
assertThat(requestBody.repeatable()).isTrue();
}
use of com.palantir.dialogue.BinaryRequestBody in project dialogue by palantir.
the class ConjureBodySerDeTest method testNonRepeatableBinaryRequestBodyProducesNonRepeatableRequest.
@Test
public void testNonRepeatableBinaryRequestBodyProducesNonRepeatableRequest() {
BodySerDe serde = DefaultConjureRuntime.builder().build().bodySerDe();
RequestBody requestBody = serde.serialize(new BinaryRequestBody() {
@Override
public void write(OutputStream _requestBody) {
}
@Override
public boolean repeatable() {
return false;
}
});
assertThat(requestBody.repeatable()).isFalse();
}
Aggregations