mirror of
https://github.com/rustfs/rustfs.git
synced 2026-08-13 08:36:54 +00:00
test: un-ignore the remaining seven global-state tests, drop one stale premise (#6048)
This commit is contained in:
@@ -11846,7 +11846,6 @@ mod tests {
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
#[ignore = "requires isolated global object layer state"]
|
||||
#[serial]
|
||||
async fn ecstore_new_succeeds_on_fresh_local_volumes() {
|
||||
let test_base_dir = format!("/tmp/rustfs_ecstore_empty_boot_{}", Uuid::new_v4());
|
||||
|
||||
@@ -2332,7 +2332,6 @@ mod tests {
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
#[ignore = "requires isolated global object layer state"]
|
||||
async fn execute_list_multipart_uploads_returns_internal_error_when_store_uninitialized() {
|
||||
let input = ListMultipartUploadsInput::builder()
|
||||
.bucket("bucket".to_string())
|
||||
@@ -2375,7 +2374,6 @@ mod tests {
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
#[ignore = "requires isolated global object layer state"]
|
||||
async fn execute_list_parts_returns_internal_error_when_store_uninitialized() {
|
||||
let input = ListPartsInput::builder()
|
||||
.bucket("bucket".to_string())
|
||||
@@ -2422,7 +2420,6 @@ mod tests {
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
#[ignore = "requires isolated global object layer state"]
|
||||
async fn execute_upload_part_copy_returns_internal_error_when_store_uninitialized() {
|
||||
let input = UploadPartCopyInput::builder()
|
||||
.bucket("bucket".to_string())
|
||||
|
||||
@@ -16668,7 +16668,6 @@ mod tests {
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
#[ignore = "requires isolated global object layer state"]
|
||||
async fn execute_get_object_attributes_returns_internal_error_when_store_uninitialized() {
|
||||
let input = GetObjectAttributesInput::builder()
|
||||
.bucket("test-bucket".to_string())
|
||||
@@ -16811,7 +16810,6 @@ mod tests {
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
#[ignore = "requires isolated global object layer state"]
|
||||
async fn execute_restore_object_returns_internal_error_when_store_uninitialized() {
|
||||
let restore_request = RestoreRequest {
|
||||
days: Some(1),
|
||||
|
||||
@@ -3452,35 +3452,6 @@ mod tests {
|
||||
assert_eq!(conditions.get("delimiter"), Some(&vec!["/".to_string()]));
|
||||
}
|
||||
|
||||
/// When policy metadata cannot be loaded, tag-based check is conservative (returns true).
|
||||
#[tokio::test]
|
||||
#[ignore = "requires isolated global object layer state"]
|
||||
async fn test_bucket_policy_needs_existing_object_tag_load_failure_is_conservative() {
|
||||
let conditions = HashMap::new();
|
||||
let store = crate::app::gating_test_env::shared_gating_ecstore().await;
|
||||
let hint = load_bucket_policy_existing_object_tag_hint(
|
||||
store.as_ref(),
|
||||
"test-bucket-no-policy-xyz-absent",
|
||||
Action::S3Action(S3Action::GetObjectAction),
|
||||
)
|
||||
.await;
|
||||
let no_groups: Option<Vec<String>> = None;
|
||||
let args = BucketPolicyArgs {
|
||||
bucket: "test-bucket-no-policy-xyz-absent",
|
||||
action: Action::S3Action(S3Action::GetObjectAction),
|
||||
is_owner: false,
|
||||
account: "",
|
||||
groups: &no_groups,
|
||||
conditions: &conditions,
|
||||
object: "obj",
|
||||
};
|
||||
let result = bucket_policy_needs_existing_object_tag_from_hint(&hint, &args).await;
|
||||
assert!(
|
||||
result,
|
||||
"when policy metadata cannot be loaded, ExistingObjectTag should be fetched conservatively"
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_bucket_policy_existing_object_tag_condition_key_detection() {
|
||||
let condition_key_policy = r#"{
|
||||
|
||||
Reference in New Issue
Block a user