Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
iv
gitlab-ce
Commits
90f9c3fb
Commit
90f9c3fb
authored
Dec 02, 2013
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of github.com:gitlabhq/gitlabhq
parents
931e6a72
5fd90cd5
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
49 additions
and
42 deletions
+49
-42
app/models/note.rb
app/models/note.rb
+4
-2
app/views/help/_layout.html.haml
app/views/help/_layout.html.haml
+6
-32
app/views/shared/_clone_panel.html.haml
app/views/shared/_clone_panel.html.haml
+3
-3
features/project/network.feature
features/project/network.feature
+3
-3
features/public/public_projects.feature
features/public/public_projects.feature
+11
-0
features/steps/project/project_network_graph.rb
features/steps/project/project_network_graph.rb
+2
-2
features/steps/public/projects_feature.rb
features/steps/public/projects_feature.rb
+10
-0
spec/models/note_spec.rb
spec/models/note_spec.rb
+10
-0
No files found.
app/models/note.rb
View file @
90f9c3fb
...
...
@@ -157,7 +157,8 @@ class Note < ActiveRecord::Base
# otherwise false is returned
def
downvote?
votable?
&&
(
note
.
start_with?
(
'-1'
)
||
note
.
start_with?
(
':-1:'
)
note
.
start_with?
(
':-1:'
)
||
note
.
start_with?
(
':thumbsdown:'
)
)
end
...
...
@@ -206,7 +207,8 @@ class Note < ActiveRecord::Base
# otherwise false is returned
def
upvote?
votable?
&&
(
note
.
start_with?
(
'+1'
)
||
note
.
start_with?
(
':+1:'
)
note
.
start_with?
(
':+1:'
)
||
note
.
start_with?
(
':thumbsup:'
)
)
end
...
...
app/views/help/_layout.html.haml
View file @
90f9c3fb
.row
.span3
{
:"data-spy"
=>
'affix'
}
.ui-box
.title
Help
%ul
.well-list
%li
%strong
=
link_to
"Workflow"
,
help_workflow_path
%li
%strong
=
link_to
"SSH keys"
,
help_ssh_path
%li
%strong
=
link_to
"GitLab Markdown"
,
help_markdown_path
%li
%strong
=
link_to
"Permissions"
,
help_permissions_path
%li
%strong
=
link_to
"API"
,
help_api_path
%li
%strong
=
link_to
"Web Hooks"
,
help_web_hooks_path
%li
%strong
=
link_to
"Rake Tasks"
,
help_raketasks_path
%li
%strong
=
link_to
"System Hooks"
,
help_system_hooks_path
%li
%strong
=
link_to
"Public Access"
,
help_public_access_path
%li
%strong
=
link_to
"Security"
,
help_security_path
%h3
.page-title
Help
%ul
.nav.nav-pills.nav-stacked
-
links
=
{
:"Workflow"
=>
help_workflow_path
,
:"SSH Keys"
=>
help_ssh_path
,
:"GitLab Markdown"
=>
help_markdown_path
,
:"Permissions"
=>
help_permissions_path
,
:"API"
=>
help_api_path
,
:"Web Hooks"
=>
help_web_hooks_path
,
:"Rake Tasks"
=>
help_raketasks_path
,
:"System Hooks"
=>
help_system_hooks_path
,
:"Public Access"
=>
help_public_access_path
,
:"Security"
=>
help_security_path
}
-
links
.
each
do
|
title
,
path
|
%li
{
class:
current_page?
(
path
)
?
'active'
:
nil
}
=
link_to
title
,
path
.span9.pull-right
=
yield
app/views/shared/_clone_panel.html.haml
View file @
90f9c3fb
.git-clone-holder
%button
{
class:
"btn
active
"
,
:"data-clone"
=>
@project
.
ssh_url_to_repo
}
SSH
%button
{
class:
"btn"
,
:"data-clone"
=>
@project
.
http_url_to_repo
}=
gitlab_config
.
protocol
.
upcase
=
text_field_tag
:project_clone
,
@project
.
url_to_repo
,
class:
"one_click_select span5"
,
readonly:
true
%button
{
class:
"btn
#{ current_user ? 'active' : '' }
"
,
:"data-clone"
=>
@project
.
ssh_url_to_repo
}
SSH
%button
{
class:
"btn
#{ current_user ? '' : 'active' }
"
,
:"data-clone"
=>
@project
.
http_url_to_repo
}=
gitlab_config
.
protocol
.
upcase
=
text_field_tag
:project_clone
,
(
current_user
?
@project
.
url_to_repo
:
@project
.
http_url_to_repo
)
,
class:
"one_click_select span5"
,
readonly:
true
features/project/network.feature
View file @
90f9c3fb
...
...
@@ -29,11 +29,11 @@ Feature: Project Network Graph
@javascript
Scenario
:
I
should filter selected tag
When
I switch ref to
"v2.1.0"
Then
page should have content not cotaining
"v2.1.0"
Then
page should have content not co
n
taining
"v2.1.0"
When
click
"Show only selected branch"
checkbox
Then
page should not have content not cotaining
"v2.1.0"
Then
page should not have content not co
n
taining
"v2.1.0"
When
click
"Show only selected branch"
checkbox
Then
page should have content not cotaining
"v2.1.0"
Then
page should have content not co
n
taining
"v2.1.0"
Scenario
:
I
should fail to look for a commit
When
I look for a commit by
";"
...
...
features/public/public_projects.feature
View file @
90f9c3fb
...
...
@@ -38,3 +38,14 @@ Feature: Public Projects Feature
Given
I sign in as a user
When
I visit project
"Internal"
page
Then
I should see project
"Internal"
home page
Scenario
:
I
visit public project page
When
I visit project
"Community"
page
Then
I should see project
"Community"
home page
And
I should see a http link to the repository
Scenario
:
I
visit public area as user
Given
I sign in as a user
When
I visit project
"Community"
page
Then
I should see project
"Community"
home page
And
I should see a ssh link to the repository
features/steps/project/project_network_graph.rb
View file @
90f9c3fb
...
...
@@ -43,13 +43,13 @@ class ProjectNetworkGraph < Spinach::FeatureSteps
sleep
2
end
Then
'page should have content not cotaining "v2.1.0"'
do
Then
'page should have content not co
n
taining "v2.1.0"'
do
within
'.network-graph'
do
page
.
should
have_content
'cleaning'
end
end
Then
'page should not have content not cotaining "v2.1.0"'
do
Then
'page should not have content not co
n
taining "v2.1.0"'
do
within
'.network-graph'
do
page
.
should_not
have_content
'cleaning'
end
...
...
features/steps/public/projects_feature.rb
View file @
90f9c3fb
...
...
@@ -83,5 +83,15 @@ class Spinach::Features::PublicProjectsFeature < Spinach::FeatureSteps
page
.
should
have_content
'Internal'
end
end
Then
'I should see a http link to the repository'
do
project
=
Project
.
find_by_name
'Community'
page
.
should
have_field
(
'project_clone'
,
with:
project
.
http_url_to_repo
)
end
Then
'I should see a ssh link to the repository'
do
project
=
Project
.
find_by_name
'Community'
page
.
should
have_field
(
'project_clone'
,
with:
project
.
url_to_repo
)
end
end
spec/models/note_spec.rb
View file @
90f9c3fb
...
...
@@ -61,6 +61,11 @@ describe Note do
note
.
should
be_upvote
end
it
"recognizes a thumbsup emoji as a vote"
do
note
=
build
(
:votable_note
,
note:
":thumbsup: for this"
)
note
.
should
be_upvote
end
it
"recognizes a -1 note"
do
note
=
create
(
:votable_note
,
note:
"-1 for this"
)
note
.
should
be_downvote
...
...
@@ -70,6 +75,11 @@ describe Note do
note
=
build
(
:votable_note
,
note:
":-1: for this"
)
note
.
should
be_downvote
end
it
"recognizes a thumbsdown emoji as a vote"
do
note
=
build
(
:votable_note
,
note:
":thumbsdown: for this"
)
note
.
should
be_downvote
end
end
let
(
:project
)
{
create
(
:project
)
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment