test poolable against s3

This commit is contained in:
Martin Algesten
2018-06-30 23:05:40 +02:00
parent e2686e3bd5
commit 548b5d80c2
4 changed files with 67 additions and 1 deletions

View File

@@ -35,6 +35,14 @@ impl ::std::fmt::Debug for Stream {
}
impl Stream {
pub fn is_poolable(&self) -> bool {
match self {
Stream::Http(_) => true,
Stream::Https(_) => true,
_ => false,
}
}
#[cfg(test)]
pub fn to_write_vec(&self) -> Vec<u8> {
match self {