Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More policy tests #56

Merged
merged 9 commits into from
Feb 7, 2025
Merged

More policy tests #56

merged 9 commits into from
Feb 7, 2025

Conversation

fczuardi
Copy link
Collaborator

@fczuardi fczuardi commented Jan 28, 2025

Em preparação para as novas actions, relativas a BucketLocking que poderão ser utilizadas em policies. Ajustes nos testes existentes foram necessários.

Aproveitei também para aproximar os testes de policy, que anteriormente não funcionavam como documentação executável (nao continha paragrafos em Markdown) para, na medida do possível serem notebooks minimamente coerentes, então este patch contém alguns refactors além do suporte a actions de locking nas policies.

@fczuardi fczuardi marked this pull request as draft January 28, 2025 14:28
@fczuardi fczuardi force-pushed the more-policy-tests branch 6 times, most recently from 8442998 to d050a8b Compare January 29, 2025 16:22
@fczuardi fczuardi marked this pull request as ready for review January 29, 2025 16:50
@fczuardi fczuardi force-pushed the more-policy-tests branch 22 times, most recently from bac2c1c to 199e94d Compare February 5, 2025 13:50
@fczuardi fczuardi changed the base branch from main to split-pr-ci February 6, 2025 15:54
@fczuardi fczuardi force-pushed the split-pr-ci branch 2 times, most recently from 66b03c8 to f3c9069 Compare February 6, 2025 16:33
Base automatically changed from split-pr-ci to main February 6, 2025 17:46
One policy test used a bucket name fixture that
could not have a proper teardown because the teardown
of the fixture didnt included a policy removal.
There is still a bad region in MagaluCloud that takes more
than a minute to make the bucket policy effective, even when
the get bucket policy request returning the expected correct
policy.

This patch introduces a new config for tweaking how many
seconds the tests should wait after putting or deleting 
a bucket policy.

This patch also adds some very ugly hackish code that I am not 
proud of, to make our tests more flexible, and a lot more
slow to finish as well.
The goal of this project is to have descriptive tests, with
markdown paragraphs explaining the examples, and not only
pytests that runs but are undocumented.

This patch improves one of our documents related to bucket
policy, the policies_test.py one.
The docs about policy only ran on pytest
@fczuardi fczuardi force-pushed the more-policy-tests branch 2 times, most recently from cc43bff to 520f1dc Compare February 6, 2025 20:58
@fczuardi fczuardi added the pr:ask For patches where you want other contributors input. See https://martinfowler.com/articles/ship-show label Feb 7, 2025
@fczuardi fczuardi merged commit e3f8ac0 into main Feb 7, 2025
10 checks passed
@fczuardi fczuardi deleted the more-policy-tests branch February 7, 2025 17:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr:ask For patches where you want other contributors input. See https://martinfowler.com/articles/ship-show
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants