Commit Graph
1320 Commits
Author SHA1 Message Date
Kamil Trzcinski 8988c8743d Fix remaining test offenses 2016-06-07 13:14:37 +02:00
Kamil Trzcinski dbf235f514 Fix tests failures 2016-06-07 10:25:57 +02:00
Kamil Trzcinski 4e38d88df5 Merge remote-tracking branch 'origin/master' into rename-ci-commit-phase-2 2016-06-06 20:24:21 +02:00
Douwe Maan 4d4a9b7c8a Merge branch 'notes-are-awardables' into 'master'
Notes are awardables

## What does this MR do?

Makes sure we can :thunder_cloud_rain: comments/notes.

## What are the relevant issue numbers?
Follows up upon !2901, depends on !3785

Closes #3655 

## Screenshots (if relevant)
TODO



See merge request !4291
2016-06-06 16:48:35 +00:00
Kamil Trzcinski 3137a7fec3 Merge branch 'rename-ci-commit' into rename-ci-commit-phase-2 2016-06-06 16:46:36 +02:00
Kamil Trzcinski d9b292f872 Merge remote-tracking branch 'origin/master' into rename-ci-commit
# Conflicts:
#	spec/features/builds_spec.rb
2016-06-06 16:33:52 +02:00
Kamil Trzcinski 842f0a3401 Merge branch 'rename-ci-commit' into rename-ci-commit-phase-2
# Conflicts:
#	features/steps/shared/builds.rb
#	spec/requests/ci/api/builds_spec.rb
2016-06-06 11:21:39 +02:00
Kamil Trzcinski 7ad7e10fee Merge remote-tracking branch 'origin/master' into rename-ci-commit 2016-06-06 11:20:17 +02:00
ZJ van de Weg 2f9c2149a3 Backend awardables on comments 2016-06-06 11:03:39 +02:00
Timothy Andrew 791cc9138b Add a U2fRegistrations table/model.
- To hold registrations from U2F devices, and to authenticate them.
- Previously, `User#two_factor_enabled` was aliased to the
  `otp_required_for_login` column on `users`.
- This commit changes things a bit:
    - `User#two_factor_enabled` is not a method anymore
    - `User#two_factor_enabled?` checks both the
      `otp_required_for_login` column, as well as `U2fRegistration`s
    - Change all instances of `User#two_factor_enabled` to
      `User#two_factor_enabled?`
- Add the `u2f` gem, and implement registration/authentication at the
  model level.
2016-06-06 12:50:31 +05:30
Grzegorz Bizon b75945e9e4 Fix rubocop offense in awardable specs 2016-06-06 07:42:12 +02:00
Kamil Trzcinski 20c7144ed2 Rename all [ci_]commit to [ci_]pipeline in specs and features 2016-06-03 16:22:26 +02:00
Z.J. van de Weg 9d491712cf Merge branch 'master' into awardables 2016-06-03 15:20:11 +02:00
Kamil Trzcinski 4d5f7aa008 Fix more places where we should rename ci_commit to pipeline 2016-06-03 14:46:17 +02:00
Kamil Trzcinski 0a51c95464 Merge remote-tracking branch 'origin/master' into rename-ci-commit 2016-06-03 13:10:01 +02:00
Kamil Trzcinski 717fdd6d42 Rename Ci::Build commit to pipeline 2016-06-03 12:29:00 +02:00
Paco Guzman 078ba8c090 issuable#labels_array explicitly load the labels
This will be useful when you want to ask for the 
number of items and later iterate over them, without 
needing to ask if the association is load or not.

So you avoid extra database queries
2016-06-02 21:43:01 +02:00
Kamil Trzcinski 021d3810c3 Rename Ci::Commit to Ci::Pipeline and rename some of the ci_commit to pipeline 2016-06-02 16:59:04 +02:00
Josh Frye 0f3df62e1a Update specs. Add CHANGELOG entry 2016-06-02 09:25:40 -04:00
Robert Speicher 7d33fba7af Merge branch 'upgrade-devise-two-factor' into 'master'
Upgrade devise, devise-two-factor, and attr_encrypted

Devise 4 includes support for Rails 5, working towards #14286. devise-async doesn't support Devise 4.0 and in 4.1 the bug that was blocking using Devise's built-in ActiveJob integration was fixed. So devise-async is removed. devise-two-factor 3.0.0 is required for Devise 4 support.

attr_encrypted and encryptor are optional but recommended upgrades for devise-two-factor 3.0.0. The mode and algorithm will need to be changed in order to update to attr_encrypted 4.x in the future.

See merge request !4216
2016-06-02 00:44:41 +00:00
Kamil Trzcinski 77cb8ec4d1 Introduce container_registry_path_with_namespace 2016-06-01 22:57:50 +02:00
Kamil Trzcinski d1fdefeecd Merge remote-tracking branch 'origin/master' into downcase-registry-repository 2016-06-01 22:56:56 +02:00
Kamil Trzcinski 6e58e7ff7c Use downcased path to container repository as this is expected path by Docker 2016-06-01 20:43:33 +02:00
Stan Hu 30aa64202b Fix note validation spec failures 2016-06-01 10:31:46 -07:00
Douwe Maan 2d084dd848 Merge branch 'separate-banzai-references' into 'master'
Separate reference gathering from rendering

This is a required step to allow batch processing when gathering references. This in turn would allow grabbing (for example) all mentioned users of an issue/merge request using a single query.

cc @rspeicher @DouweM 

See merge request !3969
2016-06-01 15:51:59 +00:00
Yorick Peterse 580d250166 Refactor Participable
There are several changes to this module:

1. The use of an explicit stack in Participable#participants
2. Proc behaviour has been changed
3. Batch permissions checking

== Explicit Stack

Participable#participants no longer uses recursion to process "self" and
all child objects, instead it uses an Array and processes objects in
breadth-first order. This allows us to for example create a single
Gitlab::ReferenceExtractor instance and pass this to any Procs. Re-using
a ReferenceExtractor removes the need for running potentially many SQL
queries every time a Proc is called on a new object.

== Proc Behaviour Changed

Previously a Proc in Participable was expected to return an Array of
User instances. This has been changed and instead it's now expected that
a Proc modifies the Gitlab::ReferenceExtractor passed to it. The return
value of the Proc is ignored.

== Permissions Checking

The method Participable#participants uses
Ability.users_that_can_read_project to check if the returned users have
access to the project of "self" _without_ running multiple SQL queries
for every user.
2016-06-01 16:22:35 +02:00
Douwe Maan d1c537ad32 Merge branch 'long.polyglot/gitlab-ce-issue_17479_todos_not_remove_when_leave_project' 2016-06-01 13:39:56 +02:00
Douwe Maan 4a50e1f051 Merge branch 'current-settings-use-request-store-during-request' 2016-06-01 12:55:00 +02:00
Z.J. van de Weg 91a7b9333b Incorportate feedback 2016-06-01 12:10:08 +02:00
Rémy Coutable 46ac3107a4 Merge branch 'issue_15557' into 'master'
Fix error 500 when sorting issues by milestone due date and filtering by labels

fixes #15557 

See merge request !4327
2016-06-01 08:42:36 +00:00
Dmitriy Zaporozhets cb261abee1 Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce 2016-06-01 11:34:45 +03:00
Felipe Artur 56f3b243ce Add leading comment space cop 2016-05-31 19:33:46 -03:00
Robert Speicher 613bcdc626 Merge branch 'data_leak' into 'master'
Confidential notes data leak

Fixes part of https://gitlab.com/gitlab-org/gitlab-ee/issues/575

See merge request !1967
2016-05-31 19:35:13 +00:00
Robert Speicher 4ec1b65bea Merge branch 'refactoring/improve-build-specs' into 'master'
Remove redundant factory namespace in build specs

Extracted from !4351.

See https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/4351#note_12154604

See merge request !4373
2016-05-31 18:48:27 +00:00
Valery Sizov 9154586ce5 Confidential notes data leak 2016-05-31 21:32:53 +03:00
Gabriel Mazetto aaaed331ba Fix hook data for Wiki Page event
Added "wiki" section and removed "repository"
2016-05-31 11:24:58 -03:00
Grzegorz Bizon 2f1a229d15 Remove redundant factory namespace in build specs
Conflicts:
	spec/models/build_spec.rb
2016-05-31 10:03:39 +02:00
Connor Shea d287315dbf Upgrade attr_encrypted and encryptor
attr_encrypted (1.3.4 => 3.0.1) Changelog:
https://github.com/attr-encrypted/attr_encrypted/blob/master/CHANGELOG.m
d

attr_encrypted 2.x included a vulnerability, so that major version is
skipped. 3.x requires that the algorithm and mode used by each
encrypted attribute is specified explicitly.

`nil` is no longer a valid value for the encrypted_value_iv field, so
it’s changed to a randomly generated string.
2016-05-30 13:51:21 -06:00
ZJ van de Weg cbd7801b3d Merge branch 'master' into awardables 2016-05-30 18:54:08 +02:00
Long Nguyen 41f8e6a4d7 Merge branch 'master' of https://gitlab.com/gitlab-org/gitlab-ce into issue_17479_todos_not_remove_when_leave_project 2016-05-30 22:24:43 +07:00
Robert Speicher f36e7ff2f9 Shut up, RuboCop
❤️
2016-05-29 23:12:19 -04:00
Grzegorz BizonandRobert Speicher dbba60029c Improve note factory 2016-05-29 15:03:00 -04:00
Grzegorz BizonandRobert Speicher fc57d36018 Minor changes in note validation specs 2016-05-29 15:03:00 -04:00
Grzegorz BizonandRobert Speicher e558edd1ce Update specs to carry out changes in note factory 2016-05-29 15:03:00 -04:00
Grzegorz BizonandRobert Speicher 0e613db76d Add more validation tests for note model 2016-05-29 15:03:00 -04:00
Grzegorz BizonandRobert Speicher bf0b51d252 Update note factory to include noteable association 2016-05-29 15:03:00 -04:00
DJ Mountney 7d57b11093 Update tests for the current_application_settings request store changes 2016-05-27 19:05:52 -07:00
Robert Speicher 1087b26bf2 Remove boilerplate spec file for Ci::RunnerProject
[ci skip]
2016-05-26 17:52:43 -04:00
Josh Frye 85495c8c85 Merge branch 'remove-main-language' into 'master'
Remove main_language and tests. Closes #14937



See merge request !4293
2016-05-26 14:49:25 +00:00
Yorick Peterse 309ca405fa Don't modify arguments in CommitRange#initialize
This method used to call strip! on input strings which will mess with
the strings if they're re-used or frozen.
2016-05-26 13:58:01 +02:00