mirror of
https://github.com/rustfs/rustfs.git
synced 2026-07-27 16:48:58 +00:00
3366bd2464
Signed-off-by: GatewayJ <835269233@qq.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Co-authored-by: GatewayJ <8352692332qq.com>
RustFS Policy Variables Tests
This directory contains comprehensive end-to-end tests for AWS IAM policy variables in RustFS.
Test Overview
The tests cover the following AWS policy variable scenarios:
- Single-value variables - Basic variable resolution like
${aws:username} - Multi-value variables - Variables that can have multiple values
- Variable concatenation - Combining variables with static text like
prefix-${aws:username}-suffix - Nested variables - Complex nested variable patterns like
${${aws:username}-test} - Deny scenarios - Testing deny policies with variables
Prerequisites
- RustFS server binary
awscurlutility for admin API calls- AWS SDK for Rust (included in the project)
Running Tests
Run All Policy Tests Using Unified Test Runner
# Run all policy tests with comprehensive reporting
# Note: Requires a RustFS server running on localhost:9000
cargo test -p e2e_test policy::test_runner::test_policy_full_suite -- --nocapture --ignored --test-threads=1
# Run only critical policy tests
cargo test -p e2e_test policy::test_runner::test_policy_critical_suite -- --nocapture --ignored --test-threads=1
Run All Policy Tests
# From the project root directory
cargo test -p e2e_test policy:: -- --nocapture --ignored --test-threads=1