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

feat: Added implementation and tests for UpdatePolicy API #106

Merged
merged 7 commits into from
Jun 16, 2021

Conversation

EmperorYP7
Copy link
Member

@EmperorYP7 EmperorYP7 commented Jun 10, 2021

Fixes #96 and #99 Partially

Signed-off-by: Yash Pandey (YP) yash.btech.cs19@iiitranchi.ac.in


Description

  • Added implementation of casbin::Enforcer::updatePolicy(...) and casbin::Enforcer::updatePolicies(...) as per casbin (GoLang) implementation.
  • Added tests for casbin::Enforcer::UpdatePolicy(), casbin::Enforcer::UpdatePolicies(), casbin::Enforcer::UpdateGroupingPolicy(), and casbin::Enforcer::UpdateGroupingPolicies() corresponding to tests in casbin (GoLang).
  • Modified GitHub Actions CI to:
    • Run CMake commands instead of makefile for UNIX
    • Test build through CMake for Windows

Important note - One of the assert tests at the end of tests/test_management_api.cpp was failing for some reason.

Signed-off-by: Yash Pandey (YP) <yash.btech.cs19@iiitranchi.ac.in>
Signed-off-by: Yash Pandey (YP) <yash.btech.cs19@iiitranchi.ac.in>
Signed-off-by: EmperorYP7 <yash.btech.cs19@iiitranchi.ac.in>
Signed-off-by: Yash Pandey (YP) <yash.btech.cs19@iiitranchi.ac.in>
Signed-off-by: Yash Pandey (YP) <yash.btech.cs19@iiitranchi.ac.in>
Signed-off-by: Yash Pandey (YP) <yash.btech.cs19@iiitranchi.ac.in>
Signed-off-by: Yash Pandey (YP) <yash.btech.cs19@iiitranchi.ac.in>
@hsluoyz
Copy link
Member

hsluoyz commented Jun 12, 2021

@xcaptain plz review.

Copy link

@xcaptain xcaptain left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, @hsluoyz let's merge it.

@hsluoyz hsluoyz merged commit 7143cc4 into casbin:master Jun 16, 2021
@github-actions
Copy link

🎉 This PR is included in version 1.20.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Upgrade to C++17
3 participants