#1824 Unit tests for ACLs
Merged by pingou. Opened by vivekanand1101.
vivekanand1101/pagure test_acls  into  master

Download 1824.patch

done on top of project_acls branch so, all those commits are here as well.

It's not fully functional, i will add/correct them after doing the documentation.

rebased

rebased

Just the tests and couple of small fixes now.

23 new commits added

  • Adjust unit test: raise exception when acl not found
  • Remove unused import from test/lib.git.py
  • Unit test: write gitolite files when group has commit access
  • Unit test: write gitolite files when group has ticket access
  • Unit test: write gitolite files when group is admin
  • Unit test: write gitolite files when user is committer
  • Unit test: writing gitolite files when the new user has jus ticket access
  • Unit Test: writing gitolite file when the new user is an admin
  • Remove unused import in test/lib_git.py
  • Unit test: private ticket comments for committers
  • user_obj should be matched to the sqlalchemy object rather than username
  • Unit test: AddGroupForm of pagure.forms
  • Unit test: AddUserForm and AddUserToGroupForm
  • Unit test: get object access for model.PagureGroup object
  • Unit Test: get obj access in lib/init for model.User
  • Unit Test: get project groups in lib/init
  • Unit Test: add group to project - check for ticket groups as well
  • Unit Test: get project users of lib/init
  • Unit Test: get access levels in lib/__init
  • Unit Test: search projects shouldn't return projects where user didn't have admin access
  • pep 8 adjustment in lib/init
  • Unit Test: add group to project with different acls
  • Unit Tests: add user to project with different acls

rebased

rebased

rebased

rebased

The "update access test changes" that i was talking about is all js, i don't know how to test that :/

I rebased this PR on the top of access_level.

However, some tests are now failing here, will look into them

rebased

Ok tests fixed :)

Let's merge this as well :)

rebased

Pull-Request has been merged by pingou

Metadata