clean-up: get rid of misplaced cfg(test)
Signed-off-by: Popa <dpopa@amazon.com> Signed-off-by: YUAN LYU <lyuyuan92@gmail.com>
This commit is contained in:
@@ -179,15 +179,6 @@ impl Headers {
|
||||
self.expect
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
pub fn new(content_length: i32, expect: bool, chunked: bool) -> Self {
|
||||
Self {
|
||||
content_length,
|
||||
expect,
|
||||
chunked,
|
||||
}
|
||||
}
|
||||
|
||||
/// Parses a byte slice into a Headers structure for a HTTP request.
|
||||
///
|
||||
/// The byte slice is expected to have the following format: </br>
|
||||
@@ -299,6 +290,16 @@ impl MediaType {
|
||||
mod tests {
|
||||
use super::*;
|
||||
|
||||
impl Headers {
|
||||
pub fn new(content_length: i32, expect: bool, chunked: bool) -> Self {
|
||||
Self {
|
||||
content_length,
|
||||
expect,
|
||||
chunked,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_default() {
|
||||
let headers = Headers::default();
|
||||
|
||||
Reference in New Issue
Block a user