@@ -214,7 +214,7 @@ mod e2e_test {
214214 std:: env:: set_current_dir ( & project_root) . unwrap ( ) ;
215215 let mut session = spawn (
216216 & format ! (
217- "{} --dir crates/pluginlab " ,
217+ "{} --dir tmp/filesystem " ,
218218 & build_command( & [ "plugin_ls.wasm" ] , "repl_logic_guest.wasm" )
219219 ) ,
220220 Some ( TEST_TIMEOUT ) ,
@@ -233,19 +233,27 @@ mod e2e_test {
233233 session. send_line ( "ls" ) . expect ( "Failed to send command" ) ;
234234 session
235235 . exp_string (
236- "D\t src \r \n D\t tests \r \n D\t wit \r \n F\t Cargo.toml \r \n F\t README.md \r \n F\t build.rs \r \n " ,
236+ "D\t data \r \n D\t documents \r \n D\t logs \r \n F\t .config \r \n F\t .hidden_file \r \n F\t README.md \r \n " ,
237237 )
238238 . expect ( "Didn't get listing of current directory" ) ;
239- session. send_line ( "ls wit" ) . expect ( "Failed to send command" ) ;
240239 session
241- . exp_string ( "F\t wit/host-api.wit\r \n F\t wit/plugin-api.wit\r \n F\t wit/shared.wit\r \n " )
242- . expect ( "Didn't get listing of wit directory" ) ;
240+ . send_line ( "ls documents" )
241+ . expect ( "Failed to send command" ) ;
242+ session
243+ . exp_string ( "D\t documents/work\r \n F\t documents/README.md\r \n F\t documents/config.json\r \n F\t documents/notes.txt\r \n " )
244+ . expect ( "Didn't get listing of documents directory" ) ;
245+ session
246+ . send_line ( "ls documents/work/projects" )
247+ . expect ( "Failed to send command" ) ;
248+ session
249+ . exp_string ( "D\t documents/work/projects/alpha\r \n D\t documents/work/projects/beta\r \n F\t documents/work/projects/.gitkeep\r \n " )
250+ . expect ( "Didn't get listing of projects directory" ) ;
243251 session
244- . send_line ( "ls wit/host-api.wit " )
252+ . send_line ( "ls data/sample.csv " )
245253 . expect ( "Failed to send command" ) ;
246254 session
247- . exp_string ( "F\t wit/host-api.wit \r \n " )
248- . expect ( "Didn't get listing of host-api.wit " ) ;
255+ . exp_string ( "F\t data/sample.csv \r \n " )
256+ . expect ( "Didn't get listing for a single file " ) ;
249257 }
250258
251259 #[ test]
@@ -255,7 +263,7 @@ mod e2e_test {
255263 std:: env:: set_current_dir ( & project_root) . unwrap ( ) ;
256264 let mut session = spawn (
257265 & format ! (
258- "{} --dir crates/pluginlab " ,
266+ "{} --dir tmp/filesystem " ,
259267 & build_command( & [ "plugin_cat.wasm" ] , "repl_logic_guest.wasm" )
260268 ) ,
261269 Some ( TEST_TIMEOUT ) ,
@@ -272,17 +280,17 @@ mod e2e_test {
272280 . exp_string ( "repl(0)>" )
273281 . expect ( "Didn't see REPL prompt" ) ;
274282 session
275- . send_line ( "cat wit " )
283+ . send_line ( "cat documents " )
276284 . expect ( "Failed to send command" ) ;
277285 session
278- . exp_string ( "cat: wit : Is a directory" )
286+ . exp_string ( "cat: documents : Is a directory" )
279287 . expect ( "Didn't get expected error output for trying to cat a directory" ) ;
280288 session
281- . send_line ( "cat wit/host-api.wit " )
289+ . send_line ( "cat documents/README.md " )
282290 . expect ( "Failed to send command" ) ;
283291 session
284- . exp_string ( "package repl:api; " )
285- . expect ( "Didn't get expected contents of host-api.wit " ) ;
292+ . exp_string ( "# Documents " )
293+ . expect ( "Didn't get expected contents of README.md " ) ;
286294 }
287295
288296 #[ test]
0 commit comments