Commit Graph

816 Commits (master)

Author SHA1 Message Date
Dmitriy Zaporozhets 063c4a069c fix wall feature. removed duplicated test 2013-03-19 14:58:58 +02:00
Dmitriy Zaporozhets b1bd3f1252 fix tests. added jquery.timeago.js 2013-03-19 14:39:32 +02:00
Dmitriy Zaporozhets fb1c85061e remove unused spec 2013-03-19 08:40:32 +02:00
Dmitriy Zaporozhets 306ea84e85 Merge pull request #3251 from AlexDenisov/api_additional_user_fields
Abilities added to /user and /sign_in requests
2013-03-18 23:20:11 -07:00
Sato Hiroyuki 92de0faf6e Fix spec errors. 2013-03-19 14:21:00 +09:00
Alex Denisov 28e7d1a8bf Abilities added to /user and /sign_in requests 2013-03-18 20:11:28 +00:00
Kevin Lyda 415bade302 Result of misspellings run.
Most of these are comments but a few are strings for users.

Might be an idea to run this from time to time:
https://github.com/lyda/misspell-check

It runs mostly clean now.
2013-03-17 19:46:54 +00:00
Dan Knox 330fe4162e Fix Wiki migration task and add more test coverage.
There was an error in the #extract_attributes_from_page method that
caused an exception when checking to see if a page named "Home"
already exists.

The check occurs to handle the renaming of the main index page to
"Home" to match the Gollum standard. If there is already a page
called "Home" then the migrator will leave that page and create
the Index page as usual. Users will need to manually rename their
old "Home" page to something else then rename their "Index" page
to "Home". Fortunately, I would be highly surprised if this case
ever comes up.

I also added more verbosity to the logging so if an error does
occur, it will be easier to track down which Wiki page is causing
the problem.
2013-03-16 18:01:48 -07:00
Dmitriy Zaporozhets 71ab011a17 Merge branch 'use_gollum_wikis' of https://github.com/DanKnox/gitlabhq into DanKnox-use_gollum_wikis
Conflicts:
	app/views/layouts/project_resource.html.haml
	app/views/wikis/edit.html.haml
	app/views/wikis/pages.html.haml
	app/views/wikis/show.html.haml
	spec/features/gitlab_flavored_markdown_spec.rb
2013-03-15 16:55:07 +02:00
Dmitriy Zaporozhets 21b1fee92c reannotated 2013-03-15 15:16:02 +02:00
Dmitriy Zaporozhets 35ad4fe7db Use wiki tab for wiki, wall, snippets 2013-03-15 14:20:03 +02:00
Dmitriy Zaporozhets ef05423f47 Finish select2-ajax for users. Added Select2Helper for tests 2013-03-14 10:16:27 +02:00
Dan Knox 7665b1de7e Use Gitlab Markdown for Markdown files and Gollum to render the rest.
This commit enables the usage of the Gitlab Markdown post processing
on all Markdown formatted files. For file types that do not contain
Markdown, it defaults to the Gollum native renderer to process the
content.
2013-03-13 23:31:08 -07:00
Dmitriy Zaporozhets 366bc32013 stub git shell mv_repository 2013-03-12 18:59:25 +02:00
Dmitriy Zaporozhets 59b36f2032 Use gitlab-shell to move repos. Requires gitlab-shell v1.1.0 2013-03-12 12:37:53 +02:00
Dmitriy Zaporozhets dc3590d619 fix api internal test 2013-03-11 15:47:44 +02:00
Dmitriy Zaporozhets a29c883b5b Merge pull request #3170 from Asquera/api/system_hooks_adjustments
API: system hook request functions and documentation updated
2013-03-10 23:56:29 -07:00
Dan Knox f0aa54e0fb Create Wiki migration task.
This commit adds a new Rake task for migrating all of your existing
Wiki content from your database into new Gollum repositories.

The bulk of the logic happens within the `WikiToGollumMigrator`
class which is decently test covered and located in the lib directory.

The new Rake task can be executed by running:

   `bundle exec rake gitlab:wiki:migrate`

It will output a nice log of every project that it migrates along
with success or failure messages.

I have used it on my own installation to migrate my Wikis successfully.
2013-03-10 19:10:44 -07:00
Dmitriy Zaporozhets 96fbef60f9 add coveralls.io to travis builds 2013-03-10 20:26:27 +02:00
Dan Knox ea9b3687db Replace current Wiki system with Gollum Wikis.
This commit replaces the old database backed Wiki system with the
excellent Gollum git based Wiki system.

The UI has been updated to allow for utilizing the extra features
that Gollum provides. Specifically:

* Edit page now allows you to choose the content format.
* Edit page allows you to provide a commit message for the change.
* History page now shows Format, Commit Message, and Commit Hash.
* A new Git Access page has been added with the Wiki Repo URL.
* The default page has been changed to Home from Index to match
the Gollum standard.

The old Wiki model has been left in tact to provide for the
development of a migration script that will move all content stored
in the old Wiki system into new Gollum Wikis.
2013-03-09 16:39:51 -08:00
Sebastian Ziebell 562de2a438 Merge branch 'master' into api/system_hooks_adjustments 2013-03-07 17:59:27 +01:00
Sebastian Ziebell 32f1eaaf0f API: system hooks API functions and documentation updated
* updated system hooks documentation and code comments
* fixed access to system hooks if no user given resulting in a `500 Server Error`
* added tests
2013-03-07 17:56:11 +01:00
Dmitriy Zaporozhets a7055be1fd Merge pull request #2835 from Asquera/fixes/api
Fix API return codes
2013-03-07 08:33:34 -08:00
Sebastian Ziebell 3374027e3a Merge branch 'master' into fixes/api, code clean up and tests fixed
Conflicts:
	doc/api/projects.md
	spec/requests/api/projects_spec.rb
2013-03-07 14:51:56 +01:00
Dmitriy Zaporozhets d2cec12632 block user should not be able to push 2013-03-07 14:18:30 +02:00
Dmitriy Zaporozhets 0d66fa89fc fix stubbed repo 2013-03-07 11:45:44 +02:00
Dmitriy Zaporozhets 7c408960ce Merge pull request #3146 from amacarthur/AdminAPIs
Additional Admin APIs
2013-03-06 22:57:24 -08:00
Dmitriy Zaporozhets afee5303ff Merge pull request #3149 from m4tthumphrey/api-deploy-keys
Added methods to manage project deploy keys via API
2013-03-06 07:43:45 -08:00
Dmitriy Zaporozhets 65d78253cb Merge pull request #3156 from m4tthumphrey/api-system-hooks
Added methods to manage system hooks from API
2013-03-06 07:42:43 -08:00
Matt Humphrey 1dd712ddc2 System hooks API. 2013-03-06 15:15:26 +00:00
Sato Hiroyuki 6224ac0647 Add and fix some tests for routing.
It is linked to #2598.
2013-03-06 16:36:01 +09:00
Sebastian Ziebell 61cfa2a7a6 Merge branch 'master' into fixes/api
Conflicts:
	lib/api/projects.rb
2013-03-05 22:29:49 +01:00
Matt Humphrey f411772e33 Project deploy keys API 2013-03-05 21:23:29 +00:00
Angus MacArthur 61ffcab60f Additional Admin APIs 2013-03-05 10:38:43 -05:00
Dmitriy Zaporozhets 2d2a235c06 fixed omniauth email spec 2013-03-05 16:50:37 +02:00
Dmitriy Zaporozhets da6b53a80e Merge branch 'omniauth_no_email_1' of https://github.com/gliptak/gitlabhq into gliptak-omniauth_no_email_1
Conflicts:
	app/observers/user_observer.rb
	spec/observers/user_observer_spec.rb
2013-03-05 16:48:18 +02:00
Andrew8xx8 0d9a6fe7b1 User's blocked field refactored to use state machine 2013-03-04 18:52:30 +04:00
Dmitriy Zaporozhets 5c3cb47c16 Merge branch 'team-and-group-descriptions' of https://github.com/Undev/gitlabhq into Undev-team-and-group-descriptions
Conflicts:
	db/schema.rb
2013-03-01 16:05:51 +02:00
Dmitriy Zaporozhets 1c517153a8 fix admin users tests 2013-02-28 19:56:36 +02:00
Andrew8xx8 ba5373805a Description added to user temas factory 2013-02-28 17:15:22 +04:00
Andrew8xx8 8caccae454 Issue helper tests improved 2013-02-28 16:11:14 +04:00
Andrew8xx8 c643b50dbd Default value for issues_tracker setting added 2013-02-28 16:11:13 +04:00
Andrew8xx8 16c720fd96 Issues helper improved 2013-02-28 16:11:13 +04:00
Andrew8xx8 0afdf39dbc New field added 2013-02-28 16:11:13 +04:00
Andrew8xx8 68a7ecdaaf Project issue tracker functions refactored 2013-02-28 16:10:00 +04:00
Andrew8xx8 e6d2e56961 Issue tracker field added to projects 2013-02-28 16:10:00 +04:00
Sebastian Ziebell d269d107d8 API: fixed adding a note
Now the correct attribute is checked if it's available or not. Also fixed a test.
2013-02-27 18:12:02 +01:00
Sebastian Ziebell 7499f65014 API: extracted helper method to validate required parameters, code clean up
Added a helper method to check if required parameters are given in an API call. Can be used
to return a `400 Bad Request` return code if a required attribute is missing.
Code clean up and fixed tests.
2013-02-27 17:50:30 +01:00
Sebastian Ziebell 3b3add35fb API: merge request documentation updated, added return codes to functions
The API documentation of merge requests contains info to status codes for all functions.
Required arguments are now checked in the merge requests API functions and a `400 Bad Request` error is
returned if they are not given.
2013-02-27 15:07:42 +01:00
Sebastian Ziebell e96d77d3db API: issues documentation and API functions updated
The issues documentation is updated with infos to status codes and the deprecated `DELETE` function and
how to close an issue. A few more tests added to check status codes of API functions.
2013-02-27 14:36:20 +01:00
Sebastian Ziebell dffc2b8a8b API: session documentation updated and test added 2013-02-27 12:58:06 +01:00
Sebastian Ziebell 873db06255 API: groups documentation updated, functions return different status codes
Updates the API documentation of groups with infos to return codes. The function calls
in the groups API have updated documentation and return `400 Bad Request` status code
if a required attribute is missing.
2013-02-27 12:34:45 +01:00
Sebastian Ziebell e119b0a0cb API repository documentation updated, includes infos to return codes
The API documentation of repository is updated and now contains infos to status codes.
Code documentation is also adjusted for `GET /projects/:id/repository/commits` and includes infos to
pagination attributes. Tests are updated.
2013-02-27 11:24:12 +01:00
Sebastian Ziebell ac4a09e9cc Merge branch 'master' into fixes/api 2013-02-27 10:16:48 +01:00
Dmitriy Zaporozhets 135418dcbf fixed popen test 2013-02-27 08:24:12 +02:00
Dmitriy Zaporozhets 4e5164338a specs for api/internal 2013-02-26 22:53:59 +02:00
Dmitriy Zaporozhets 2c5e4955c0 specs for Gitlab::Popen 2013-02-26 22:53:46 +02:00
Dmitriy Zaporozhets 9c252a60c1 remove tests for unexisting methods 2013-02-26 11:17:02 +02:00
Dmitriy Zaporozhets d7b667fee2 Merge branch 'state-machine-stage-2' of https://github.com/Undev/gitlabhq into Undev-state-machine-stage-2
Conflicts:
	app/models/merge_request.rb
2013-02-26 10:38:40 +02:00
Dmitriy Zaporozhets c9b1df1201 Fixing tests 2013-02-25 23:16:34 +02:00
Dmitriy Zaporozhets 7bab81b199 Move git post push logic to service 2013-02-25 21:21:38 +02:00
Dmitriy Zaporozhets 9611640e38 Merge pull request #3052 from Undev/system-hook-observer-improves
System hooks code & logic refactoring
2013-02-25 10:15:23 -08:00
Sebastian Ziebell 9ee6c58acc API documentation updated for project snippets.
The API Documentation for project snippets got infos to return codes. Tests are added
to check status codes when handling project snippets.
2013-02-21 21:13:46 +01:00
Sebastian Ziebell ce9e35c295 API: Fixes tests for changed hook deletion 2013-02-21 21:04:16 +01:00
Dmitriy Zaporozhets 99b6750e15 Restore old order for MR lists. Fix failing tests 2013-02-21 16:26:09 +02:00
Dmitriy Zaporozhets 4a137651ec Fix merge request closed filter. Fixed one more test 2013-02-21 14:11:24 +02:00
Dmitriy Zaporozhets cce14e0b01 Removing ambiguity and non-working selectors 2013-02-21 13:28:05 +02:00
Dmitriy Zaporozhets 5aeaf248f1 Fixing rspec after upgrade to capybara pt1 2013-02-21 13:09:47 +02:00
Dmitriy Zaporozhets 37187336b1 Team features are green now 2013-02-21 12:27:52 +02:00
Dmitriy Zaporozhets 28da2a8bdc Monkeypatch satellite call for merge request in tests 2013-02-21 11:44:33 +02:00
Dmitriy Zaporozhets 42ce2c1080 improve selectors to pass capybara 2.0 2013-02-21 11:27:22 +02:00
Dmitriy Zaporozhets 03f6a28ec0 move capybara scenarios to spec/features 2013-02-21 10:41:37 +02:00
Dmitriy Zaporozhets 9f722427e5 Add LoginHelpers to feature type 2013-02-21 10:41:13 +02:00
Sebastian Ziebell 4a60c377b8 API documentation update for milestones
Updated the milestones API documentation and added return codes descriptions.
2013-02-20 22:51:59 +01:00
Sebastian Ziebell 33c1463645 API: fixes return codes for notes, documentation updated
The notes API documentation updated with return codes. API now returns `400 Bad Request` if
required attributes are not present. Return codes are documented now, also tested in added tests.
The documentation now reflects the current state of the API.
2013-02-20 22:17:05 +01:00
Andrew8xx8 e2d94e0719 State machine added for merge_status field 2013-02-20 17:49:48 +04:00
Sebastian Ziebell f0e417091c Merge branch 'master' into fixes/api
Conflicts:
	spec/requests/api/projects_spec.rb
2013-02-20 14:30:11 +01:00
Sebastian Ziebell 512d826cc3 API: fixes test if project limit is reached
Fixes a test that checks if the project limit is reached.
2013-02-20 14:15:04 +01:00
Matt Humphrey dddf6eab2d Removed unnecessary paramter hash. Also tidied up hash format in hook creation spec 2013-02-20 11:45:54 +00:00
Sebastian Ziebell eefb27f5ae Merge branch 'master' into fixes/api
Conflicts:
	spec/requests/api/projects_spec.rb
2013-02-20 12:43:32 +01:00
Matt Humphrey 33c513274d Fix RESTfulness of project hook deletions by API 2013-02-20 11:35:36 +00:00
Sebastian Ziebell 1b97a2eee8 API: fixes return codes, documentation updated with status codes, tests added
The users API updated with return codes, e.g. if required parameters are missing
a `400 Bad Request` error is returned instead of `404`. Fixes return codes of functions,
e.g. deletion of a ssh key is an idempotent function now.
The API documentation is updated to reflect the current status of the API. Descriptions
are more detailed and complete, infos to return values are added to all functions.
2013-02-20 12:23:56 +01:00
Andrew8xx8 aa1780d03c System hooks execution moved to System hook service 2013-02-20 14:53:15 +04:00
Dmitriy Zaporozhets b7ac654b88 Merge pull request #2988 from Asquera/error_project_limit
API: creating last project before limit returns 404
2013-02-20 02:47:30 -08:00
Dmitriy Zaporozhets 25e4c512d4 Merge pull request #3011 from Asquera/fix_access_to_nonvisible_hook
API: fixes visibility of project hook
2013-02-20 02:45:07 -08:00
Dmitriy Zaporozhets 155703c613 Merge branch 'state-machine' of https://github.com/Undev/gitlabhq into Undev-state-machine
Conflicts:
	app/models/issue.rb
	app/models/merge_request.rb
2013-02-19 11:01:19 +02:00
Andrew8xx8 41e97a766b Creating test values moved to before 2013-02-18 17:52:39 +04:00
Andrew8xx8 69698aacbc Additional tests added to Issue 2013-02-18 14:43:50 +04:00
Andrew8xx8 b607c70e8f Additional tests added to Milestone 2013-02-18 14:43:50 +04:00
Andrew8xx8 1644117a1a Issue uses StateMachine now 2013-02-18 14:43:50 +04:00
Andrew8xx8 0b512af803 Milestone uses StateMachine now 2013-02-18 14:43:50 +04:00
Andrew8xx8 29f70acc98 Merge Request uses StateMachine now 2013-02-18 14:43:50 +04:00
Andrew8xx8 b45e9aefd3 Merge Request uses StateMachine now 2013-02-18 14:43:50 +04:00
Andrew8xx8 f97296597c Issuable consern uses StateMachine now 2013-02-18 14:43:49 +04:00
Andrew8xx8 8db3920c01 State renamed to merge_status 2013-02-18 14:43:49 +04:00
Jaakko Kantojärvi 27f4cf7542 Tests to validate that invalid keys are rejected 2013-02-17 21:31:20 +02:00
Sebastian Ziebell e9d3b96595 API: fixes visibility of project hook
When a user is not authorized to see the list of hooks for a project, he is
still able to access the hooks separately. For example if access to
`GET /projects/:id/hooks` fails and returns a `403 Unauthorized` error it is
still possible to access a hook directly via `GET /projects/:id/hooks/:hook_id`.

Fixes access, also added tests to check access and status codes of hooks.
2013-02-16 14:42:49 +01:00
Sebastian Ziebell 5417fbfecd Test to check 404 error when project id not found 2013-02-14 21:00:05 +01:00
Sebastian Ziebell c8b92a4be2 Merge branch 'master' into fixes/api 2013-02-14 17:02:16 +01:00
Sebastian Ziebell c305eb31aa API: tests that check status codes for project branches and hooks
Status code 422 (Unprocessable Entity) returned if invalid url is given when creating
or updating a project hook.
2013-02-14 16:55:33 +01:00