You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
currently we use many /tmp/xxx temp directory on db testing, and needs manually delete the dir in the end of test.
It's better to use some crate like tempfile to help us.
pros:
no need to delete folders manually. programmers may forget to add remove code after testing.
no need to worry about folder name collision. each test will always use different folder.
although xline only supports test on linux, it's not bad to add some cross-platform ability.
things to do:
add crate to [dev-dependencies] and replace /tmp/xxx path
currently we use many
/tmp/xxx
temp directory on db testing, and needs manually delete the dir in the end of test.It's better to use some crate like tempfile to help us.
pros:
things to do:
[dev-dependencies]
and replace/tmp/xxx
path/tmp/xxx
path not in test mod, ex. crates/xline/src/server/command.rs, use std::env::temp_dir instead.The text was updated successfully, but these errors were encountered: