mirror of
https://github.com/marcoallegretti/WEFT_OS.git
synced 2026-03-27 01:13:09 +00:00
test(appd): add QueryAppState dispatch test for unknown session returning NotFound
This commit is contained in:
parent
7a07e46c55
commit
abdefa3388
1 changed files with 13 additions and 0 deletions
|
|
@ -454,6 +454,19 @@ mod tests {
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[tokio::test]
|
||||||
|
async fn dispatch_query_app_state_unknown_returns_not_found() {
|
||||||
|
let reg = make_registry();
|
||||||
|
let resp = dispatch(Request::QueryAppState { session_id: 9999 }, ®).await;
|
||||||
|
assert!(matches!(
|
||||||
|
resp,
|
||||||
|
Response::AppState {
|
||||||
|
state: AppStateKind::NotFound,
|
||||||
|
..
|
||||||
|
}
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn registry_launch_increments_id() {
|
fn registry_launch_increments_id() {
|
||||||
let mut reg = SessionRegistry::default();
|
let mut reg = SessionRegistry::default();
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue