Xuanwo commented on code in PR #2803:
URL:
https://github.com/apache/incubator-opendal/pull/2803#discussion_r1285741896
##########
core/tests/behavior/list.rs:
##########
@@ -84,6 +86,95 @@ pub async fn test_list_dir(op: Operator) -> Result<()> {
Ok(())
}
+/// List dir with metakey
+pub async fn test_list_dir_with_metakey(op: Operator) -> Result<()> {
+ let parent = uuid::Uuid::new_v4().to_string();
+ let path = format!("{parent}/{}", uuid::Uuid::new_v4());
+ debug!("Generate a random file: {}", &path);
+ let (content, size) = gen_bytes();
+
+ op.write(&path, content).await.expect("write must succeed");
+
+ let mut obs = op
+ .lister_with(&format!("{parent}/"))
+ .metakey(
+ Metakey::Mode
+ | Metakey::CacheControl
+ | Metakey::ContentDisposition
+ | Metakey::ContentLength
+ | Metakey::ContentMd5
+ | Metakey::ContentRange
+ | Metakey::ContentType
+ | Metakey::Etag
+ | Metakey::LastModified
+ | Metakey::Version,
Review Comment:
I'm guessing it's ok in test code. I prefer to keep current design of
`Metakey` layout.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]