Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-03-16Add latest changes from gitlab-org/gitlab@13-10-stable-eev13.10.0-rc40GitLab Bot
2020-07-20Add latest changes from gitlab-org/gitlab@13-2-stable-eeGitLab Bot
2020-03-02Add latest changes from gitlab-org/gitlab@masterGitLab Bot
2020-02-07Add latest changes from gitlab-org/gitlab@masterGitLab Bot
2019-04-01Add # frozen_string_literal to spec/modelsThong Kuah
Adds `# frozen_string_literal: true` to spec/models ruby files
2019-03-06Allow protected branch creation via web and APIPatrick Bajao
This commit includes changes to add `UserAccess#can_create_branch?` which will check whether the user is allowed to create a branch even if it matches a protected branch. This is used in `Gitlab::Checks::BranchCheck` when the branch name matches a protected branch. A `push_to_create_protected_branch` ability in `ProjectPolicy` has been added to allow Developers and above to create protected branches.
2017-08-03Change all `:empty_project` to `:project`Robert Speicher
2017-07-27Use described_class when possibleRémy Coutable
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-07-27Remove superfluous lib: true, type: redis, service: true, models: true, ↵Rémy Coutable
services: true, no_db: true, api: true Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-05-18Enable the RSpec/EmptyExampleGroup copRémy Coutable
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-04-03Moved Project#protected_branch? to ProtectedBranch, similar for tagsJames Edwards-Jones
2017-04-03Extract ProtectedRef ConcernJames Edwards-Jones
2016-07-05Support wildcard matches for protected branches at the model level.Timothy Andrew
1. The main implementation is in the `ProtectedBranch` model. The wildcard is converted to a Regex and compared. This has been tested thoroughly. - While `Project#protected_branch?` is the main entry point, `project#open_branches` and `project#developers_can_push_to_protected_branch?` have also been modified to work with wildcard protected branches. - The regex is memoized (within the `ProtectedBranch` instance) 2. Improve the performance of `Project#protected_branch?` - This method is called from `Project#open_branches` once _per branch_ in the project, to check if that branch is protected or not. - Before, `#protected_branch?` was making a database call every time it was invoked (in the above case, that amounts to once per branch), which is expensive. - This commit caches the list of protected branches in memory, which reduces the number of database calls down to 1. - A downside to this approach is that `#protected_branch?` _could_ return a stale value (due to the caching), but this is an acceptable tradeoff. 3. Remove the (now) unused `Project#protected_branch_names` method. - This was previously used to check for protected branch status.
2016-05-09Remove the annotate gem and delete old annotationsJeroen van Baarsen
In 8278b763d96ef10c6494409b18b7eb541463af29 the default behaviour of annotation has changes, which was causing a lot of noise in diffs. We decided in #17382 that it is better to get rid of the whole annotate gem, and instead let people look at schema.rb for the columns in a table. Fixes: #17382
2015-12-09Tag model specsDouwe Maan
2015-02-12Updated rspec to rspec 3.x syntaxJeroen van Baarsen
Signed-off-by: Jeroen van Baarsen <jeroenvanbaarsen@gmail.com>
2015-01-22Annotate modelsDmitriy Zaporozhets
2014-06-27Remove mass assgnment specsDmitriy Zaporozhets
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-04-09Re-annotate modelsDmitriy Zaporozhets
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2013-02-05Fixed: post-receive, project remove, testsDmitriy Zaporozhets
2013-01-05Tests are fixed nowDmitriy Zaporozhets
2013-01-05Fix some tests. Use travis-ci 1.9.2Dmitriy Zaporozhets
2012-11-19Annotated. schema updatedDmitriy Zaporozhets
2012-10-09AnnotatedDmitriy Zaporozhets
2012-10-09tests fixAndrey Kumanyaev
2012-09-26set activerecord whitelist_attributes to trueNihad Abbasov
2012-08-29Add more coverage for model validations and associationsRobert Speicher
2012-08-29Remove annotations from specsRobert Speicher
2012-08-11Fully embrace Ruby 1.9 hash syntaxRobert Speicher
Didn't bother with files in db/, config/, or features/
2012-08-02Remove useless Protected branch testrandx
2012-06-26Reannotatedrandx
2012-05-26lib/ refactoring. Module Gitlabhq renamed to Gitlabrandx
2012-05-11Add spec for ProtectedBranch.Robb Kidd
2012-02-16ProtectedBranches model, Master permission for repo\n Allow push to ↵Dmitriy Zaporozhets
protected branch for masters only