feat(userspace): shell runs programs (ls, cat) via spawn w/ terminal+storage+args page; ext4 holes read as zeros; storage re-attach same buffer
This commit is contained in:
@@ -67,10 +67,14 @@ fn nothing_works_before_attaching() {
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn a_client_attaches_once() {
|
||||
fn attaching_again_hands_back_the_same_buffer() {
|
||||
let mut s = server();
|
||||
Client::attach(&mut s, 0);
|
||||
assert_eq!(call(&mut s, 0, StorageRequest::Attach).0, StorageResponse::Error);
|
||||
let (first, cap) = call(&mut s, 0, StorageRequest::Attach);
|
||||
assert_eq!(call(&mut s, 0, StorageRequest::Attach), (first, cap));
|
||||
// Not a new client: the other seven places are still free.
|
||||
for badge in 1..8 {
|
||||
assert!(matches!(call(&mut s, badge, StorageRequest::Attach).0, StorageResponse::Attached { .. }));
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
||||
Reference in New Issue
Block a user