mirror of
https://github.com/actix/actix-web.git
synced 2024-12-20 23:26:44 +00:00
fix tests
This commit is contained in:
parent
7036656ae4
commit
3623383e83
1 changed files with 3 additions and 3 deletions
|
@ -245,8 +245,8 @@ impl<I, E> Reply<I, E> {
|
|||
}
|
||||
|
||||
#[cfg(test)]
|
||||
pub(crate) fn as_msg(&self) -> &T {
|
||||
match self.0 {
|
||||
pub(crate) fn as_msg(&self) -> &I {
|
||||
match self.0.as_ref().unwrap() {
|
||||
ReplyResult::Ok(ref resp) => resp,
|
||||
_ => panic!(),
|
||||
}
|
||||
|
@ -254,7 +254,7 @@ impl<I, E> Reply<I, E> {
|
|||
|
||||
#[cfg(test)]
|
||||
pub(crate) fn as_err(&self) -> Option<&E> {
|
||||
match self.0 {
|
||||
match self.0.as_ref().unwrap() {
|
||||
ReplyResult::Err(ref err) => Some(err),
|
||||
_ => None,
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue